* [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon
@ 2025-01-08 20:12 Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 1/7] gnu: Add rust-uname-0.1 Karl Hallsby via Guix-patches via
` (7 more replies)
0 siblings, 8 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:12 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Ludovic Courtès, Maxim Cournoyer
This train adds the necessary Rust packages requried to build the
xen-guest-agent package, builds it, and defines a service-type for
running it as a daemon.
The guest agent allows the virtualizing host (Xen) to receive
information about the running OS guest and the host to send graceful
versions of commands to the guest.
The service-type is mutually exclusive with the xe-guest-utilities
service-type and daemon introduced in issue #72249.
Karl Hallsby (7):
gnu: Add rust-uname-0.1.
gnu: Add rust-xenstore-sys-0.3
gnu: Add rust-xenstore-sys-0.2
gnu: Add rust-xenstore-rs-0.7
gnu: Add rust-xenstore-rs-0.6
gnu: Add xen-guest-agent.
services: Add xen-guest-agent-service-type.
doc/guix.texi | 24 +++++++
gnu/packages/crates-io.scm | 112 ++++++++++++++++++++++++++++++++
gnu/packages/virtualization.scm | 51 +++++++++++++++
gnu/services/virtualization.scm | 34 +++++++++-
4 files changed, 220 insertions(+), 1 deletion(-)
base-commit: 4eaeff997907bc1b67884a6dc087756a50f175e2
prerequisite-patch-id: daabcb5995f03ed867a27648e973e1c2203f2bc9
prerequisite-patch-id: 10ca9a0912c5ab863ed39f14959581e75962ada9
--
2.46.0
^ permalink raw reply [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 1/7] gnu: Add rust-uname-0.1.
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
@ 2025-01-08 20:18 ` Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 2/7] gnu: Add rust-xenstore-sys-0.3 Karl Hallsby via Guix-patches via
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:18 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Efraim Flashner
* gnu/packages/crates-io.scm (rust-uname-0.1): New variable.
Generated by "guix import".
Change-Id: I8ea68f2575742659600754ac932bd86388a6af34
---
gnu/packages/crates-io.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm
index b94cc9a60a..f8b74e5d78 100644
--- a/gnu/packages/crates-io.scm
+++ b/gnu/packages/crates-io.scm
@@ -90523,6 +90523,26 @@ (define-public rust-unarray-0.1
(description "Utilities for working with uninitialized arrays.")
(license (list license:expat license:asl2.0))))
+(define-public rust-uname-0.1
+ (package
+ (name "rust-uname")
+ (version "0.1.1")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (crate-uri "uname" version))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32 "1j1xd1rryml4j1hf07kahva9d5ym8m9jz9z20hfdpr1jrbq8jbxp"))))
+ (build-system cargo-build-system)
+ (arguments
+ `(#:cargo-inputs (("rust-libc" ,rust-libc-0.2))))
+ (home-page "https://github.com/icorderi/rust-uname")
+ (synopsis "Name and information about current kernel")
+ (description
+ "This package provides Name and information about current kernel.")
+ (license (list license:expat license:asl2.0))))
+
(define-public rust-uncased-0.9
(package
(name "rust-uncased")
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 2/7] gnu: Add rust-xenstore-sys-0.3
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 1/7] gnu: Add rust-uname-0.1 Karl Hallsby via Guix-patches via
@ 2025-01-08 20:18 ` Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 3/7] gnu: Add rust-xenstore-sys-0.2 Karl Hallsby via Guix-patches via
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:18 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Efraim Flashner
* gnu/packages/crates-io.scm (rust-xenstore-sys-0.3): New variable.
Generated by "guix import".
Change-Id: I91b20f282325f6a1c3548eff981eb5158d982cc1
---
gnu/packages/crates-io.scm | 20 ++++++++++++++++++++
1 file changed, 20 insertions(+)
diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm
index f8b74e5d78..2705b0f42f 100644
--- a/gnu/packages/crates-io.scm
+++ b/gnu/packages/crates-io.scm
@@ -95556,6 +95556,26 @@ (define-public rust-xdg-home-1
(description "The user's home directory as per the XDG Specification.")
(license license:expat)))
+(define-public rust-xenstore-sys-0.3
+ (package
+ (name "rust-xenstore-sys")
+ (version "0.3.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (crate-uri "xenstore-sys" version))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32 "02dpapjj251z3b3qm3xlx71jjs0inbq55l2jcjh8g16yvz1a8r58"))))
+ (build-system cargo-build-system)
+ (arguments
+ `(#:cargo-inputs (("rust-bindgen" ,rust-bindgen-0.53)
+ ("rust-pkg-config" ,rust-pkg-config-0.3))))
+ (home-page "https://github.com/Wenzel/xenstore-sys")
+ (synopsis "Rust FFI bindings for libxenstore")
+ (description "This package provides Rust FFI bindings for libxenstore.")
+ (license license:gpl3)))
+
(define-public rust-xflags-macros-0.2
(package
(name "rust-xflags-macros")
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 3/7] gnu: Add rust-xenstore-sys-0.2
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 1/7] gnu: Add rust-uname-0.1 Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 2/7] gnu: Add rust-xenstore-sys-0.3 Karl Hallsby via Guix-patches via
@ 2025-01-08 20:18 ` Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 4/7] gnu: Add rust-xenstore-rs-0.7 Karl Hallsby via Guix-patches via
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:18 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Efraim Flashner
* gnu/packages/crates-io.scm (rust-xenstore-sys-0.2): New variable.
Generated by "guix import".
Change-Id: Ifdcf25fb557cc040e42a3029437da645198cedb6
---
gnu/packages/crates-io.scm | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm
index 2705b0f42f..42e1f1e9b6 100644
--- a/gnu/packages/crates-io.scm
+++ b/gnu/packages/crates-io.scm
@@ -95576,6 +95576,27 @@ (define-public rust-xenstore-sys-0.3
(description "This package provides Rust FFI bindings for libxenstore.")
(license license:gpl3)))
+(define-public rust-xenstore-sys-0.2
+ (package
+ (inherit rust-xenstore-sys-0.3)
+ (name "rust-xenstore-sys")
+ (version "0.2.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (crate-uri "xenstore-sys" version))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32 "1xrjy0d3cg9qrznfsfjrgha8si1dvdyfx3g7c76hbb7lnim5vmj7"))))
+ (build-system cargo-build-system)
+ (arguments
+ `(#:cargo-inputs (("rust-bindgen" ,rust-bindgen-0.53)
+ ("rust-pkg-config" ,rust-pkg-config-0.3))))
+ (home-page "https://github.com/Wenzel/xenstore-sys")
+ (synopsis "Rust FFI bindings for libxenstore")
+ (description "This package provides Rust FFI bindings for libxenstore.")
+ (license license:gpl3)))
+
(define-public rust-xflags-macros-0.2
(package
(name "rust-xflags-macros")
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 4/7] gnu: Add rust-xenstore-rs-0.7
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
` (2 preceding siblings ...)
2025-01-08 20:18 ` [bug#75445] [PATCH 3/7] gnu: Add rust-xenstore-sys-0.2 Karl Hallsby via Guix-patches via
@ 2025-01-08 20:18 ` Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 5/7] gnu: Add rust-xenstore-rs-0.6 Karl Hallsby via Guix-patches via
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:18 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Efraim Flashner
* gnu/packages/crates-io.scm (rust-xenstore-rs-0.7): New variable.
Generated by "guix import".
Change-Id: Id227093e9647716dab92430eb86e7d5bf89daf86
---
gnu/packages/crates-io.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm
index 42e1f1e9b6..2d7f9515bd 100644
--- a/gnu/packages/crates-io.scm
+++ b/gnu/packages/crates-io.scm
@@ -95556,6 +95556,31 @@ (define-public rust-xdg-home-1
(description "The user's home directory as per the XDG Specification.")
(license license:expat)))
+(define-public rust-xenstore-rs-0.7
+ (package
+ (name "rust-xenstore-rs")
+ (version "0.7.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (crate-uri "xenstore-rs" version))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32 "02izqilgfby7g14ndr76fmqrpcgx9q4m1rgky6r7ld5p73i3w0zv"))))
+ (build-system cargo-build-system)
+ (arguments
+ `(#:cargo-inputs (("rust-futures" ,rust-futures-0.3)
+ ("rust-libc" ,rust-libc-0.2)
+ ("rust-libloading" ,rust-libloading-0.8)
+ ("rust-log" ,rust-log-0.4)
+ ("rust-tokio" ,rust-tokio-1)
+ ("rust-xenstore-sys" ,rust-xenstore-sys-0.3))
+ #:cargo-development-inputs (("rust-clap" ,rust-clap-4))))
+ (home-page "https://github.com/Wenzel/xenstore")
+ (synopsis "Rust FFI bindings for libxenstore")
+ (description "This package provides Rust FFI bindings for libxenstore.")
+ (license license:gpl3)))
+
(define-public rust-xenstore-sys-0.3
(package
(name "rust-xenstore-sys")
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 5/7] gnu: Add rust-xenstore-rs-0.6
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
` (3 preceding siblings ...)
2025-01-08 20:18 ` [bug#75445] [PATCH 4/7] gnu: Add rust-xenstore-rs-0.7 Karl Hallsby via Guix-patches via
@ 2025-01-08 20:18 ` Karl Hallsby via Guix-patches via
2025-01-08 20:19 ` [bug#75445] [PATCH 6/7] gnu: Add xen-guest-agent Karl Hallsby via Guix-patches via
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:18 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Efraim Flashner
* gnu/packages/crates-io.scm (rust-xenstore-rs-0.6): New variable.
Change-Id: I11cc6f5f014201c89d7e306b73ca8aa928f7a2cb
---
gnu/packages/crates-io.scm | 26 ++++++++++++++++++++++++++
1 file changed, 26 insertions(+)
diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm
index 2d7f9515bd..f3abebeece 100644
--- a/gnu/packages/crates-io.scm
+++ b/gnu/packages/crates-io.scm
@@ -95581,6 +95581,32 @@ (define-public rust-xenstore-rs-0.7
(description "This package provides Rust FFI bindings for libxenstore.")
(license license:gpl3)))
+(define-public rust-xenstore-rs-0.6
+ (package
+ (inherit rust-xenstore-rs-0.7)
+ (name "rust-xenstore-rs")
+ (version "0.6.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (crate-uri "xenstore-rs" version))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32 "1i8wdif8q2cxbrmcp2jxcqg95a4yfsp1m3j4yldcgad3ksl5l4qs"))))
+ (build-system cargo-build-system)
+ (arguments
+ `(#:cargo-inputs (("rust-futures" ,rust-futures-0.3)
+ ("rust-libc" ,rust-libc-0.2)
+ ("rust-libloading" ,rust-libloading-0.8)
+ ("rust-log" ,rust-log-0.4)
+ ("rust-tokio" ,rust-tokio-1)
+ ("rust-xenstore-sys" ,rust-xenstore-sys-0.2))
+ #:cargo-development-inputs (("rust-clap" ,rust-clap-4))))
+ (home-page "https://github.com/Wenzel/xenstore")
+ (synopsis "Rust FFI bindings for libxenstore")
+ (description "This package provides Rust FFI bindings for libxenstore.")
+ (license license:gpl3)))
+
(define-public rust-xenstore-sys-0.3
(package
(name "rust-xenstore-sys")
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 6/7] gnu: Add xen-guest-agent.
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
` (4 preceding siblings ...)
2025-01-08 20:18 ` [bug#75445] [PATCH 5/7] gnu: Add rust-xenstore-rs-0.6 Karl Hallsby via Guix-patches via
@ 2025-01-08 20:19 ` Karl Hallsby via Guix-patches via
2025-01-08 20:19 ` [bug#75445] [PATCH 7/7] services: Add xen-guest-agent-service-type Karl Hallsby via Guix-patches via
2025-01-09 15:10 ` [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Efraim Flashner
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:19 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Sharlatan Hellseher
* gnu/packages/virtualization.scm (xen-guest-agent): New variable.
This is intended to replace xe-guest-utilities in the long run. Right now it
is a drop-in replacement.
Change-Id: I6277edc2298c6154d722f7f206e7955222228710
---
gnu/packages/virtualization.scm | 51 +++++++++++++++++++++++++++++++++
1 file changed, 51 insertions(+)
diff --git a/gnu/packages/virtualization.scm b/gnu/packages/virtualization.scm
index 3b162474af..95e36b7d1b 100644
--- a/gnu/packages/virtualization.scm
+++ b/gnu/packages/virtualization.scm
@@ -79,6 +79,7 @@ (define-module (gnu packages virtualization)
#:use-module (gnu packages compression)
#:use-module (gnu packages containers)
#:use-module (gnu packages cpio)
+ #:use-module (gnu packages crates-io)
#:use-module (gnu packages cross-base)
#:use-module (gnu packages crypto)
#:use-module (gnu packages cryptsetup)
@@ -119,6 +120,7 @@ (define-module (gnu packages virtualization)
#:use-module (gnu packages libbsd)
#:use-module (gnu packages libusb)
#:use-module (gnu packages linux)
+ #:use-module (gnu packages llvm)
#:use-module (gnu packages lua)
#:use-module (gnu packages m4)
#:use-module (gnu packages man)
@@ -160,6 +162,7 @@ (define-module (gnu packages virtualization)
#:use-module (gnu packages xml)
#:use-module (gnu packages xorg)
#:use-module ((guix licenses) #:prefix license:)
+ #:use-module (guix build-system cargo)
#:use-module (guix build-system cmake)
#:use-module (guix build-system gnu)
#:use-module (guix build-system go)
@@ -2860,6 +2863,54 @@ (define-public xe-guest-utilities
about events that change the virtualized hardware, such as hotplugging.")
(license license:bsd-2)))
+(define-public xen-guest-agent
+ (package
+ (name "xen-guest-agent")
+ (version "0.4.0")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://gitlab.com/xen-project/xen-guest-agent")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1ab6mgrvnd49m0ay9fbfyd02xaf3qvkwhyyavra4a7wpz0brg54h"))))
+ (build-system cargo-build-system)
+ (arguments
+ `(#:install-source? #f
+ #:cargo-inputs (("rust-futures" ,rust-futures-0.3)
+ ("rust-libc" ,rust-libc-0.2)
+ ("rust-tokio" ,rust-tokio-1)
+ ("rust-netlink-packet-core" ,rust-netlink-packet-core-0.7)
+ ("rust-netlink-packet-route" ,rust-netlink-packet-route-0.18)
+ ("rust-netlink-proto" ,rust-netlink-proto-0.11)
+ ("rust-rtnetlink" ,rust-rtnetlink-0.14)
+ ("rust-async-stream" ,rust-async-stream-0.3)
+ ("rust-os-info" ,rust-os-info-3)
+ ("rust-pnet-datalink" ,rust-pnet-datalink-0.34)
+ ("rust-pnet-base" ,rust-pnet-base-0.34)
+ ("rust-ipnetwork" ,rust-ipnetwork-0.17)
+ ("rust-log" ,rust-log-0.4)
+ ("rust-env-logger" ,rust-env-logger-0.10)
+ ("rust-clap" ,rust-clap-4)
+ ("rust-xenstore-rs" ,rust-xenstore-rs-0.6)
+ ;; Unix-specific dependencies
+ ("rust-uname" ,rust-uname-0.1)
+ ("rust-syslog" ,rust-syslog-6)
+ ("rust-sysctl" ,rust-sysctl-0.5))))
+ (native-inputs
+ (list pkg-config
+ xen ; Pull in Xen for libxenstore
+ clang))
+ (home-page "https://gitlab.com/xen-project/xen-guest-agent")
+ (synopsis "Provides guest VM information to hosting Xen hypervisor")
+ (description "The agent gathers some guest information, and writes them to
+xenstore so tooling in dom0 can read it. The default behavior is to be
+compatible with the XAPI toolstack as currently used in XCP-ng and Citrix
+Hypervisor/Xenserver, and thus roughly follow what @code{xe-guest-utilities}
+is doing.")
+ (license license:agpl3)))
+
(define-public osinfo-db-tools
(package
(name "osinfo-db-tools")
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 7/7] services: Add xen-guest-agent-service-type.
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
` (5 preceding siblings ...)
2025-01-08 20:19 ` [bug#75445] [PATCH 6/7] gnu: Add xen-guest-agent Karl Hallsby via Guix-patches via
@ 2025-01-08 20:19 ` Karl Hallsby via Guix-patches via
2025-01-09 15:10 ` [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Efraim Flashner
7 siblings, 0 replies; 9+ messages in thread
From: Karl Hallsby via Guix-patches via @ 2025-01-08 20:19 UTC (permalink / raw)
To: 75445; +Cc: Karl Hallsby, Ludovic Courtès, Maxim Cournoyer
* gnu/services/virtualization.scm (xen-guest-agent-configuration,
xen-guest-agent-service-type): New variables.
* doc/guix.texi: Document them.
Change-Id: Id1b1f4fc2b193d73f4401e74a214222dfe1b6ea7
---
doc/guix.texi | 24 +++++++++++++++++++++++
gnu/services/virtualization.scm | 34 ++++++++++++++++++++++++++++++++-
2 files changed, 57 insertions(+), 1 deletion(-)
diff --git a/doc/guix.texi b/doc/guix.texi
index ee827717a1..89f153146a 100644
--- a/doc/guix.texi
+++ b/doc/guix.texi
@@ -37365,6 +37365,30 @@ Virtualization Services
@end table
@end deftp
+@code{xe-guest-utilities} is the standard guest utilities used for Xen
+guests. More recently the Xen Project has been working to develop
+@code{xen-guest-agent}, a modern drop-in replacement for
+@code{xe-guest-utilities}. While they nearly have feature-parity,
+@code{xen-guest-agent} currently lacks some of the features of its
+predecessor, namely disk metrics and ``PV drivers version''.
+
+@defvar xen-guest-agent-service-type
+Service type for the Xen guest agent service.
+@end defvar
+
+@deftp {Data Type} xen-guest-agent-configuration
+Configuration for the @code{xen-guest-agent} service.
+
+@table @asis
+@item @code{package} (default: @code{xen-guest-agent})
+The Xen guest agent package to use.
+@end table
+@end deftp
+
+@quotation Warning
+@code{xe-guest-utilities} and @code{xen-guest-agent} are mutually exclusive.
+@end quotation
+
@anchor{build-vm}
@subsubheading Virtual Build Machines
diff --git a/gnu/services/virtualization.scm b/gnu/services/virtualization.scm
index 874abcd73f..b697ae9526 100644
--- a/gnu/services/virtualization.scm
+++ b/gnu/services/virtualization.scm
@@ -113,7 +113,9 @@ (define-module (gnu services virtualization)
qemu-guest-agent-service-type
xe-guest-utilities-configuration
- xe-guest-utilities-service-type))
+ xe-guest-utilities-service-type
+ xen-guest-agent-configuration
+ xen-guest-agent-service-type))
(define (uglify-field-name field-name)
(let ((str (symbol->string field-name)))
@@ -1083,6 +1085,36 @@ (define xe-guest-utilities-service-type
(default-value (xe-guest-utilities-configuration))
(description "Run the Xen guest management utilities.")))
+(define-configuration/no-serialization xen-guest-agent-configuration
+ (package
+ (package xen-guest-agent)
+ "Xen guest agent package."))
+
+(define (generate-xen-guest-agent-documentation)
+ "Generate documentation for xen-guest-agent-configuration fields"
+ (generate-documentation
+ `((xen-guest-agent-configuration ,xen-guest-agent-configuration-fields))
+ 'xen-guest-agent-configuration))
+
+(define (xen-guest-agent-shepherd-service config)
+ (list
+ (shepherd-service
+ (provision '(xen-guest-agent))
+ (requirement '(networking user-processes udev))
+ (documentation "Run the Xen guest management agent.")
+ (start #~(make-forkexec-constructor
+ (list #$(file-append xen-guest-agent "/bin/xen-guest-agent"))))
+ (stop #~(make-kill-destructor)))))
+
+(define xen-guest-agent-service-type
+ (service-type
+ (name 'xen-guest-agent)
+ (extensions
+ (list (service-extension shepherd-root-service-type
+ xen-guest-agent-shepherd-service)))
+ (default-value (xen-guest-agent-configuration))
+ (description "Run the Xen guest management utilities.")))
+
\f
;;;
;;; Secrets for guest VMs.
--
2.46.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
` (6 preceding siblings ...)
2025-01-08 20:19 ` [bug#75445] [PATCH 7/7] services: Add xen-guest-agent-service-type Karl Hallsby via Guix-patches via
@ 2025-01-09 15:10 ` Efraim Flashner
7 siblings, 0 replies; 9+ messages in thread
From: Efraim Flashner @ 2025-01-09 15:10 UTC (permalink / raw)
To: Karl Hallsby; +Cc: 75445, Ludovic Courtès, Maxim Cournoyer
[-- Attachment #1: Type: text/plain, Size: 1704 bytes --]
I pushed 3 of the 5 rust- packages (not the 2 that weren't actually
needed) and xen-guest-agent, and I'll let you all handle the service.
On Wed, Jan 08, 2025 at 02:12:48PM -0600, Karl Hallsby via Guix-patches via wrote:
> This train adds the necessary Rust packages requried to build the
> xen-guest-agent package, builds it, and defines a service-type for
> running it as a daemon.
>
> The guest agent allows the virtualizing host (Xen) to receive
> information about the running OS guest and the host to send graceful
> versions of commands to the guest.
>
> The service-type is mutually exclusive with the xe-guest-utilities
> service-type and daemon introduced in issue #72249.
>
> Karl Hallsby (7):
> gnu: Add rust-uname-0.1.
> gnu: Add rust-xenstore-sys-0.3
> gnu: Add rust-xenstore-sys-0.2
> gnu: Add rust-xenstore-rs-0.7
> gnu: Add rust-xenstore-rs-0.6
> gnu: Add xen-guest-agent.
> services: Add xen-guest-agent-service-type.
>
> doc/guix.texi | 24 +++++++
> gnu/packages/crates-io.scm | 112 ++++++++++++++++++++++++++++++++
> gnu/packages/virtualization.scm | 51 +++++++++++++++
> gnu/services/virtualization.scm | 34 +++++++++-
> 4 files changed, 220 insertions(+), 1 deletion(-)
>
>
> base-commit: 4eaeff997907bc1b67884a6dc087756a50f175e2
> prerequisite-patch-id: daabcb5995f03ed867a27648e973e1c2203f2bc9
> prerequisite-patch-id: 10ca9a0912c5ab863ed39f14959581e75962ada9
> --
> 2.46.0
>
--
Efraim Flashner <efraim@flashner.co.il> אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2025-01-09 15:11 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-01-08 20:12 [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 1/7] gnu: Add rust-uname-0.1 Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 2/7] gnu: Add rust-xenstore-sys-0.3 Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 3/7] gnu: Add rust-xenstore-sys-0.2 Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 4/7] gnu: Add rust-xenstore-rs-0.7 Karl Hallsby via Guix-patches via
2025-01-08 20:18 ` [bug#75445] [PATCH 5/7] gnu: Add rust-xenstore-rs-0.6 Karl Hallsby via Guix-patches via
2025-01-08 20:19 ` [bug#75445] [PATCH 6/7] gnu: Add xen-guest-agent Karl Hallsby via Guix-patches via
2025-01-08 20:19 ` [bug#75445] [PATCH 7/7] services: Add xen-guest-agent-service-type Karl Hallsby via Guix-patches via
2025-01-09 15:10 ` [bug#75445] [PATCH 0/7] Add xen-guest-agent and daemon Efraim Flashner
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/guix.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).