feat: add netvm shell for raw shel access
This commit is contained in:
parent
24a254a914
commit
d1229c0f45
|
@ -70,6 +70,19 @@ qga() {
|
|||
fi
|
||||
}
|
||||
|
||||
function cmd_shell(){
|
||||
qemu-system-x86_64 \
|
||||
-m 512M \
|
||||
--machine q35 \
|
||||
-nographic \
|
||||
-net none \
|
||||
-cdrom /guest.img \
|
||||
-boot order=d \
|
||||
-device qemu-xhci \
|
||||
-device virtio-serial \
|
||||
-device virtserialport,chardev=qga0,name=org.qemu.guest_agent.0
|
||||
}
|
||||
|
||||
function cmd_start(){
|
||||
[ ! -f "${LOCKFILE}" ] || { echo "Error: Netvm already running"; exit 1; }
|
||||
local net_args=""
|
||||
|
@ -235,6 +248,8 @@ cmd_usage() {
|
|||
Start headless network vm in the background
|
||||
netvm stop
|
||||
Stop headless network vm
|
||||
netvm shell
|
||||
Start interactive network vm in the foreground
|
||||
netvm status
|
||||
Get hostname and uptime from running network vm
|
||||
netvm push <local-path> <remote-path>
|
||||
|
|
Loading…
Reference in New Issue