Skip to content
Snippets Groups Projects
Commit 351f2475 authored by Recolic's avatar Recolic :house_with_garden:
Browse files

.sample

parent 325676e2
No related branches found
No related tags found
No related merge requests found
......@@ -87,7 +87,8 @@ function start_vm_if_not_running () {
# start it
[[ ! -f "vm/$name/disk.img" ]] && echo2 "In start_vm, disk image vm/$name/disk.img doesn't exist. Did init_vm fail?" && return 1
echo2 "+ Starting VM $name with options_txt '$options_txt' and uuid $uuid..."
nohup qemu-system-x86_64 --uuid "$uuid" -drive file="vm/$name/disk.img",if=virtio -cdrom "vm/$name/initimg.iso" -cpu host --enable-kvm -bios /usr/share/edk2-ovmf/x64/OVMF.fd -net nic,model=rtl8139 "${options[@]}" >> tmp/qemu.log 2>&1 & disown
[[ -f "vm/$name/initimg.iso" ]] && options+=(-cdrom "vm/$name/initimg.iso")
nohup qemu-system-x86_64 --uuid "$uuid" -drive file="vm/$name/disk.img",if=virtio -cpu host --enable-kvm -bios /usr/share/edk2-ovmf/x64/OVMF.fd -net nic,model=rtl8139 "${options[@]}" >> tmp/qemu.log 2>&1 & disown
}
function do_init () {
......
# name;options (name will be trimmed, options will be passed as-is)
instance1;-m 2G -smp 2 -vnc :11 -net user,hostfwd=tcp::30471-:22
gitlab-ci;-m 4G -smp 4 -vnc :12 -net user,hostfwd=tcp::30473-:22
#httptest ;-m 1G -smp 1 -vnc :13 -net user,hostfwd=tcp::30474-:22
#httptest ;-m 1G -smp 1 -vnc :13 -net user,hostfwd=tcp::30474-:22,hostfwd=tcp::30480-:80
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment