only run cleanup if we've started ray in local mode and actually started the processes (#228)

This commit is contained in:
Robert Nishihara
2016-07-08 00:14:26 -07:00
committed by Philipp Moritz
parent eee50416a1
commit 875b20e397
3 changed files with 11 additions and 5 deletions
+1 -1
View File
@@ -82,7 +82,7 @@ def _start_ray(node_ip_addresses, username, key_file, num_workers_per_node, work
start_scheduler_command = """
cd "{}";
source ../setup-env.sh;
python -c "import ray; ray.services.start_scheduler(\\\"{}:10001\\\")" > start_scheduler.out 2> start_scheduler.err < /dev/null &
python -c "import ray; ray.services.start_scheduler(\\\"{}:10001\\\", local=False)" > start_scheduler.out 2> start_scheduler.err < /dev/null &
""".format(scripts_directory, node_ip_addresses[0])
run_command_over_ssh(node_ip_addresses[0], username, key_file, start_scheduler_command)