summaryrefslogtreecommitdiff
path: root/systemd/system/qemu
diff options
context:
space:
mode:
Diffstat (limited to 'systemd/system/qemu')
-rwxr-xr-xsystemd/system/qemu8
1 files changed, 7 insertions, 1 deletions
diff --git a/systemd/system/qemu b/systemd/system/qemu
index 603a437..ca35498 100755
--- a/systemd/system/qemu
+++ b/systemd/system/qemu
@@ -6,6 +6,12 @@ args+=(
-pidfile "/run/qemu-$1/pid"
-vnc unix:"/run/qemu-$1/vnc.sock"
-monitor unix:"/run/qemu-$1/monitor.sock",server,nowait
+ -serial unix:"/run/qemu-$1/ttyS0.sock",server
-daemonize
)
-exec qemu-system-"${system}" "${args[@]}"
+{
+ until [[ -S /run/qemu-$1/ttyS0.sock ]]; do :; done
+ exec socat UNIX-CONNECT:"/run/qemu-$1/ttyS0.sock" STDOUT > >(exec cat)
+} &
+qemu-system-"${system}" "${args[@]}"
+systemd-notify --ready