def start_heron_tools(masters, cl_args):
single_master = list(masters)[<NUM_LIT:0>]<EOL>wait_for_master_to_start(single_master)<EOL>cmd = "<STR_LIT>"% (get_nomad_path(cl_args), get_heron_tools_job_file(cl_args))<EOL>Log.info("<STR_LIT>" % single_master)<EOL>if not is_self(single_master):<EOL><INDENT>cmd = ssh_remote_execute(cmd, single_master, cl_args)<EOL><DEDENT>Log.debug(cmd)<EOL>pid = subprocess.Popen(cmd,<EOL>shell=True,<EOL>stdout=subprocess.PIPE,<EOL>stderr=subprocess.PIPE)<EOL>return_code = pid.wait()<EOL>output = pid.communicate()<EOL>Log.debug("<STR_LIT>" % (return_code, output))<EOL>if return_code != <NUM_LIT:0>:<EOL><INDENT>Log.error("<STR_LIT>" % (single_master, output[<NUM_LIT:1>]))<EOL>sys.exit(-<NUM_LIT:1>)<EOL><DEDENT>wait_for_job_to_start(single_master, "<STR_LIT>")<EOL>Log.info("<STR_LIT>")<EOL>
Start Heron tracker and UI