mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-10-04 08:42:38 +00:00
query-machine-capabilities: add systemd service file
Add a systemd service that runs the query-machine-capabilities binary at boot time to ensure that the machine capabilities are stored in the host-hw-capabilities.json file. Signed-off-by: Markus Frank <m.frank@proxmox.com>
This commit is contained in:
parent
dabf4600ba
commit
88abf3643e
@ -1,6 +1,7 @@
|
||||
DESTDIR=
|
||||
PREFIX=/usr
|
||||
BINDIR=${PREFIX}/libexec/qemu-server
|
||||
SERVICEDIR=/lib/systemd/system
|
||||
|
||||
CC ?= gcc
|
||||
CFLAGS += -O2 -fanalyzer -Werror -Wall -Wextra -Wpedantic -Wtype-limits -Wl,-z,relro -std=gnu11
|
||||
@ -12,6 +13,7 @@ query-machine-capabilities: query-machine-capabilities.c
|
||||
install: query-machine-capabilities
|
||||
install -d ${DESTDIR}/${BINDIR}
|
||||
install -m 0755 query-machine-capabilities ${DESTDIR}${BINDIR}
|
||||
install -m 0644 query-machine-capabilities.service ${DESTDIR}${SERVICEDIR}
|
||||
|
||||
.PHONY: clean
|
||||
clean:
|
||||
|
@ -0,0 +1,13 @@
|
||||
[Unit]
|
||||
Description=PVE Query Machine Capabilities
|
||||
RequiresMountsFor=/run
|
||||
Before=pve-ha-lrm.service
|
||||
Before=pve-guests.service
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/libexec/qemu-server/query-machine-capabilities
|
||||
Type=oneshot
|
||||
RemainAfterExit=yes
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Reference in New Issue
Block a user