mirror of
https://github.com/vdsm/virtual-dsm.git
synced 2026-09-20 15:04:20 +00:00
fix: Improve argument ordering (#1386)
This commit is contained in:
+9
-7
@@ -28,11 +28,11 @@ configureMonitor() {
|
|||||||
MON_OPTS=""
|
MON_OPTS=""
|
||||||
[ -n "$QMP" ] && MON_OPTS+=" -qmp $QMP"
|
[ -n "$QMP" ] && MON_OPTS+=" -qmp $QMP"
|
||||||
[ -n "$MONITOR" ] && MON_OPTS+=" -monitor $MONITOR"
|
[ -n "$MONITOR" ] && MON_OPTS+=" -monitor $MONITOR"
|
||||||
|
MON_OPTS="${MON_OPTS# }"
|
||||||
|
|
||||||
local name="${APP// /-}"
|
local name="${APP// /-}"
|
||||||
MON_OPTS+=" -name $name,process=$PROCESS,debug-threads=on"
|
ID_OPTS="-name $name,process=$PROCESS,debug-threads=on"
|
||||||
MON_OPTS+=" -pidfile $QEMU_PID"
|
PID_OPTS="-pidfile $QEMU_PID"
|
||||||
MON_OPTS="${MON_OPTS# }"
|
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
@@ -48,8 +48,8 @@ configureMachine() {
|
|||||||
MAC_OPTS+=",vmport=off,dump-guest-core=off,hpet=off${KVM_OPTS}"
|
MAC_OPTS+=",vmport=off,dump-guest-core=off,hpet=off${KVM_OPTS}"
|
||||||
|
|
||||||
UUID=$(strip "$UUID")
|
UUID=$(strip "$UUID")
|
||||||
[ -n "$UUID" ] && MAC_OPTS+=" -uuid $UUID"
|
[ -n "$UUID" ] && ID_OPTS+=" -uuid $UUID"
|
||||||
[ -n "${SM_BIOS:-}" ] && MAC_OPTS+=" $SM_BIOS"
|
[ -n "${SM_BIOS:-}" ] && ID_OPTS+=" $SM_BIOS"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
@@ -82,8 +82,10 @@ configureVirtioDevices() {
|
|||||||
|
|
||||||
buildArguments() {
|
buildArguments() {
|
||||||
|
|
||||||
local default="-nodefaults -boot strict=on"
|
local default="-nodefaults"
|
||||||
ARGS="$default $CPU_OPTS $RAM_OPTS $MAC_OPTS $DISPLAY_OPTS $MON_OPTS $SERIAL_OPTS $NET_OPTS $DISK_OPTS $BOOT_OPTS $DEV_OPTS $ARGUMENTS"
|
local boot="-boot strict=on"
|
||||||
|
|
||||||
|
ARGS="$default $MAC_OPTS $CPU_OPTS $RAM_OPTS $ID_OPTS $PID_OPTS $DISPLAY_OPTS $MON_OPTS $SERIAL_OPTS $NET_OPTS $DISK_OPTS $boot $BOOT_OPTS $DEV_OPTS $ARGUMENTS"
|
||||||
|
|
||||||
# Collapse whitespace after optional argument groups are assembled so empty
|
# Collapse whitespace after optional argument groups are assembled so empty
|
||||||
# features cannot leave malformed spacing in the final QEMU command.
|
# features cannot leave malformed spacing in the final QEMU command.
|
||||||
|
|||||||
Reference in New Issue
Block a user