diff options
Diffstat (limited to 'share')
-rwxr-xr-x | share/build-scripts/debconf | 6 | ||||
-rw-r--r-- | share/systemd/qemu@.service | 13 |
2 files changed, 19 insertions, 0 deletions
diff --git a/share/build-scripts/debconf b/share/build-scripts/debconf index 8307695..a20212f 100755 --- a/share/build-scripts/debconf +++ b/share/build-scripts/debconf @@ -1163,6 +1163,7 @@ EOF echo 'fs0:\EFI\progress-linux\grubx64.efi' > "${DIRECTORY}/boot/efi/EFI/boot/startup.nsh" sed -i \ + -e "s|@DIRECTORY@|${SYSTEM_BASE_DIR}/${NAME}|g" \ -e "s|@BOOT_METHOD@|${BOOT_METHOD}|g" \ -e "s|@CPU@|${CPU}|g" \ -e "s|@MEMORY@|${MEMORY}|g" \ @@ -1359,9 +1360,14 @@ fi case "${BOOT_METHOD}" in qemu) + SYSTEM_BASE_DIR="${VMS}" Create_vm_disk Mount_vm_disk ;; + + systemd-nspawn) + SYSTEM_BASE_DIR="${MACHINES}" + ;; esac case "${INSTALLER}" in diff --git a/share/systemd/qemu@.service b/share/systemd/qemu@.service new file mode 100644 index 0000000..8c36df4 --- /dev/null +++ b/share/systemd/qemu@.service @@ -0,0 +1,13 @@ +[Unit] +Description="Container: %i" +Documentation=man:compute-tools + +[Service] +Type=simple +ExecStart=/usr/bin/container start -n %i --nspawn +ExecStartPost=/usr/bin/container start -n %i --start +#ExecStopPost=/usr/bin/container stop -n %i --clean --no-notification +KillMode=mixed + +[Install] +WantedBy=multi-user.target |