systemd: Switch virtvboxd to common templates

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
This commit is contained in:
Andrea Bolognani 2023-09-19 20:19:18 +02:00
parent e6331394e5
commit 6453fae2da
3 changed files with 3 additions and 30 deletions

View File

@ -57,11 +57,8 @@ if conf.has('WITH_VBOX')
virt_daemon_units += {
'service': 'virtvboxd',
'service_in': files('virtvboxd.service.in'),
'name': 'Libvirt vbox',
'socket_in': libvirtd_socket_in,
'socket_ro_in': libvirtd_socket_ro_in,
'socket_admin_in': libvirtd_socket_admin_in,
'service_extra_in': files('virtvboxd.service.extra.in'),
}
openrc_init_files += {

View File

@ -0,0 +1,2 @@
[Unit]
After=remote-fs.target

View File

@ -1,26 +0,0 @@
[Unit]
Description=Virtualization vbox daemon
Conflicts=libvirtd.service
Requires=virtvboxd.socket
Requires=virtvboxd-ro.socket
Requires=virtvboxd-admin.socket
After=network.target
After=dbus.service
After=apparmor.service
After=remote-fs.target
Documentation=man:virtvboxd(8)
Documentation=https://libvirt.org
[Service]
Type=notify
Environment=VIRTVBOXD_ARGS="--timeout 120"
EnvironmentFile=-@initconfdir@/virtvboxd
ExecStart=@sbindir@/virtvboxd $VIRTVBOXD_ARGS
ExecReload=/bin/kill -HUP $MAINPID
Restart=on-failure
[Install]
WantedBy=multi-user.target
Also=virtvboxd.socket
Also=virtvboxd-ro.socket
Also=virtvboxd-admin.socket