[autoscaler] docker run options (#3921)

Adds support for docker options, allowing for use of nvidia-docker.

Closes #2657.
This commit is contained in:
Kristian Hartikainen
2019-02-13 12:26:28 -08:00
committed by Richard Liaw
parent 4347ab644e
commit 729d0b2825
10 changed files with 419 additions and 101 deletions
+8 -3
View File
@@ -627,6 +627,11 @@ def submit(cluster_config_file, screen, tmux, stop, start, cluster_name,
@cli.command()
@click.argument("cluster_config_file", required=True, type=str)
@click.argument("cmd", required=True, type=str)
@click.option(
"--docker",
is_flag=True,
default=False,
help="Runs command in the docker container specified in cluster_config.")
@click.option(
"--stop",
is_flag=True,
@@ -652,9 +657,9 @@ def submit(cluster_config_file, screen, tmux, stop, start, cluster_name,
help="Override the configured cluster name.")
@click.option(
"--port-forward", required=False, type=int, help="Port to forward.")
def exec_cmd(cluster_config_file, cmd, screen, tmux, stop, start, cluster_name,
port_forward):
exec_cluster(cluster_config_file, cmd, screen, tmux, stop, start,
def exec_cmd(cluster_config_file, cmd, docker, screen, tmux, stop, start,
cluster_name, port_forward):
exec_cluster(cluster_config_file, cmd, docker, screen, tmux, stop, start,
cluster_name, port_forward)