add logging for command, actually specify host (duh)
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
@@ -30,7 +30,8 @@ def apply_key_permissions(keyfile):
|
||||
run(["Icacls", keyfile])
|
||||
|
||||
def run_command(host, command, auth):
|
||||
run(["ssh", "-i", auth, "-o", "StrictHostKeyChecking=no", "-o", "PasswordAuthentication=no", "sh", "-c", command], check=True)
|
||||
print(f">> [exec] {host} {command}")
|
||||
run(["ssh", "-i", auth, "-o", "StrictHostKeyChecking=no", "-o", "PasswordAuthentication=no", host, "sh", "-c", command], check=True)
|
||||
|
||||
def make_parent_dirs(target, auth):
|
||||
if is_target_http(target):
|
||||
@@ -44,7 +45,7 @@ def deploy(source, target, auth):
|
||||
deploy_file(source_file, target, auth)
|
||||
|
||||
def deploy_file(source_file, target, auth):
|
||||
print(f">> {source_file} -> {target}")
|
||||
print(f">> [deploy] {source_file} -> {target}")
|
||||
if is_target_http(target):
|
||||
run(["curl", "--user", auth, target, "--upload-file", source_file], check=True)
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user