diff --git a/test-iso.sh b/test-iso.sh index a5857c7..0083f4d 100755 --- a/test-iso.sh +++ b/test-iso.sh @@ -82,7 +82,7 @@ echo "[3/4] Booting VM from ISO..." echo "" echo "VM Configuration:" echo " CPU: 2 cores" -echo " RAM: 4GB" +echo " RAM: 2GB" echo " Disk: 16GB" echo " Boot: $ISO_PATH" echo "" @@ -91,20 +91,21 @@ echo "Console output will be saved to: $CONSOLE_LOG" echo "To monitor console: tail -f $CONSOLE_LOG" echo "" -# Start VM with QEMU -# Using qemu-system from host for better performance -# But we could also use Docker if needed -qemu-system-x86_64 \ - -m 4096 \ +# Start VM with QEMU using screen session +# Using screen to manage long-running QEMU process +screen -dmS football-iso-test \ + qemu-system-x86_64 \ + -m 2048 \ -smp 2 \ -drive file="$DISK_PATH",format=qcow2 \ -drive file="$ISO_PATH",media=cdrom,readonly=on \ -boot d \ -nographic \ -serial file:"$CONSOLE_LOG" \ - -display none \ - -pidfile "$VM_PID_FILE" \ - -daemonize + -display none + +# Save QEMU PID for later use +pgrep -f "qemu-system-x86_64.*$DISK_PATH" | head -1 > "$VM_PID_FILE" echo "✅ VM started (PID: $(cat $VM_PID_FILE 2>/dev/null || echo 'unknown'))" echo ""