mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-21 18:11:35 +00:00
Allow forcing qemu backend to use container via command line
`linuxkit run --containerized foo` Signed-off-by: Ian Campbell <ian.campbell@docker.com>
This commit is contained in:
parent
b0e506aa71
commit
bb787b49be
@ -63,6 +63,9 @@ func runQemu(args []string) {
|
|||||||
cpus := flags.String("cpus", "1", "Number of CPUs")
|
cpus := flags.String("cpus", "1", "Number of CPUs")
|
||||||
mem := flags.String("mem", "1024", "Amount of memory in MB")
|
mem := flags.String("mem", "1024", "Amount of memory in MB")
|
||||||
|
|
||||||
|
// Backend configuration
|
||||||
|
qemuContainerized := flags.Bool("containerized", false, "Run qemu in a container")
|
||||||
|
|
||||||
publishFlags := multipleFlag{}
|
publishFlags := multipleFlag{}
|
||||||
flags.Var(&publishFlags, "publish", "Publish a vm's port(s) to the host (default [])")
|
flags.Var(&publishFlags, "publish", "Publish a vm's port(s) to the host (default [])")
|
||||||
|
|
||||||
@ -95,6 +98,7 @@ func runQemu(args []string) {
|
|||||||
Arch: *arch,
|
Arch: *arch,
|
||||||
CPUs: *cpus,
|
CPUs: *cpus,
|
||||||
Memory: *mem,
|
Memory: *mem,
|
||||||
|
Containerized: *qemuContainerized,
|
||||||
PublishedPorts: publishFlags,
|
PublishedPorts: publishFlags,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user