Skip to content
Snippets Groups Projects
Commit ab387130 authored by gsalin's avatar gsalin
Browse files

add final slash for curl to work

parent fc5315e4
No related branches found
No related tags found
1 merge request!151copy bash script on remote server to be able to execute it
......@@ -78,8 +78,8 @@ def create_symbolik_link (ids_dump_path, output_list, user_script, username, pas
# user_script = user_script.replace("/home/ng6/work/", "/oldwork/ng6/")
# user_script = user_script.replace("/work/ng6/", "/oldwork/ng6/")
# logging.getLogger("create_symbolik_link").debug("user_script = "+user_script)
logging.getLogger("create_symbolik_link").debug("Copy " + user_script + " to " + os.path.join(server,output_folder))
cmd = "curl --insecure --user '"+username+":"+password+"' -T "+user_script+" sftp://"+os.path.join(server,output_folder)
logging.getLogger("create_symbolik_link").debug("Copy " + user_script + " to " + os.path.join(server,output_folder+'/'))
cmd = "curl --insecure --user '"+username+":"+password+"' -T "+user_script+" sftp://"+os.path.join(server,output_folder+'/')
args = shlex.split(cmd)
process = subprocess.Popen(args, shell=False, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
stdout, stderr = process.communicate()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment