use --detach only on docker run
This commit is contained in:
parent
bce71c4574
commit
73cb1ca67e
|
@ -13,7 +13,11 @@ def create_container(container_options, ip=None, docker_gpus=False, shm_size=64,
|
|||
# Sanitize and validate input
|
||||
container_options = sanitize_input(container_options)
|
||||
|
||||
command = ["docker", ("create" if paused else "run"), "--detach", "--tty"]
|
||||
command = ["docker", ("create" if paused else "run")]
|
||||
|
||||
if not paused:
|
||||
command.append("--detach")
|
||||
command.append("--tty")
|
||||
|
||||
if "name" in container_options:
|
||||
command.extend(["--name", container_options["name"]])
|
||||
|
|
Loading…
Reference in New Issue