diff mbox series

contrib: add udev qemu-guest-agent.rules

Message ID 316d1414d0af33f22fff24d16ad953629e7416bb.1625758833.git.crobinso@redhat.com (mailing list archive)
State New, archived
Headers show
Series contrib: add udev qemu-guest-agent.rules | expand

Commit Message

Cole Robinson July 8, 2021, 3:40 p.m. UTC
Fedora/RHEL and Debian have shipped an identical file for years.
This pairs with contrib/systemd/qemu-guest-agent.service

Signed-off-by: Cole Robinson <crobinso@redhat.com>
---
 contrib/systemd/qemu-guest-agent.rules | 2 ++
 1 file changed, 2 insertions(+)
 create mode 100644 contrib/systemd/qemu-guest-agent.rules

Comments

Daniel P. Berrangé July 8, 2021, 4:36 p.m. UTC | #1
On Thu, Jul 08, 2021 at 11:40:33AM -0400, Cole Robinson wrote:
> Fedora/RHEL and Debian have shipped an identical file for years.
> This pairs with contrib/systemd/qemu-guest-agent.service
> 
> Signed-off-by: Cole Robinson <crobinso@redhat.com>
> ---
>  contrib/systemd/qemu-guest-agent.rules | 2 ++
>  1 file changed, 2 insertions(+)
>  create mode 100644 contrib/systemd/qemu-guest-agent.rules

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>

> diff --git a/contrib/systemd/qemu-guest-agent.rules b/contrib/systemd/qemu-guest-agent.rules
> new file mode 100644
> index 0000000000..8a290abbd3
> --- /dev/null
> +++ b/contrib/systemd/qemu-guest-agent.rules
> @@ -0,0 +1,2 @@
> +SUBSYSTEM=="virtio-ports", ATTR{name}=="org.qemu.guest_agent.0", \
> +  TAG+="systemd" ENV{SYSTEMD_WANTS}="qemu-guest-agent.service"

If you fancy doing more work on top, I'd suggest we wire things
up so that 'make install' will install both this new file and
the .service file, with 'meson' detecting whether we're on a
systemd enabled OS </handwaving> libvirt has some meson rules
you can crib for this purpose.

Not a blocker for merging this particular patch though.


Regards,
Daniel
diff mbox series

Patch

diff --git a/contrib/systemd/qemu-guest-agent.rules b/contrib/systemd/qemu-guest-agent.rules
new file mode 100644
index 0000000000..8a290abbd3
--- /dev/null
+++ b/contrib/systemd/qemu-guest-agent.rules
@@ -0,0 +1,2 @@ 
+SUBSYSTEM=="virtio-ports", ATTR{name}=="org.qemu.guest_agent.0", \
+  TAG+="systemd" ENV{SYSTEMD_WANTS}="qemu-guest-agent.service"