WIP:aryan/build #2

Draft
chopper wants to merge 7 commits from aryan/build into main
Showing only changes of commit c0f174f551 - Show all commits

View file

@ -1,2 +1,21 @@
from subprocess import Popen, PIPE
import os
user = os.getlogin()
image = f"/home/{user}/safe/debian.qcow2"
initialize = [
Outdated
Review

Documentation suggests using getuser

Documentation suggests using [getuser](https://docs.python.org/3/library/getpass.html#getpass.getuser)
"qemu-system-x86_64",
"-enable-kvm",
"-m", "2G",
"-nic", "user,hostfwd=tcp::5555-:22",
"-drive", "file=%s,media=disk,if=virtio" % image,
# "-display", "sdl",
]
Outdated
Review

Isn't this far too low? It should also be adjustable via argparse

Isn't this far too low? It should also be adjustable via argparse
Popen(["cp", "/home/chopper/safe/debian.qcow2", f"/home/{user}/nnnnndebian.qcow2"]) #copy the base image to a directory with everyones virtual machines.
Outdated
Review

This port should be configurable, otherwise we can't run several vms at the same time. Best put it in argparse

This port should be configurable, otherwise we can't run several vms at the same time. Best put it in argparse
Popen(initialize)
Outdated
Review

What are these doing here?

What are these doing here?