diff --git a/action.yml b/action.yml index d8f6c38..99f28e4 100644 --- a/action.yml +++ b/action.yml @@ -17,6 +17,10 @@ inputs: sftp-host: description: "Sftp host" required: true + sftp-port: + description: "Sftp port" + default: "22" + required: true runs: using: "docker" image: "Containerfile" diff --git a/entrypoint.sh b/entrypoint.sh index e4d239b..613467e 100644 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -1,4 +1,4 @@ #!/bin/sh set -e -lftp -e "set sftp:auto-confirm yes; open -u $INPUT_SFTP_USER,$INPUT_SFTP_PW $SFTP_INPUT_HOST; mirror -v --no-perms --delete --reverse $INPUT_SOURCE $INPUT_DESTINATION; quit" +lftp -e "set sftp:auto-confirm yes; open -p $INPUT_SFTP_PORT -u $INPUT_SFTP_USER,$INPUT_SFTP_PW $SFTP_INPUT_HOST; mirror -v --no-perms --delete --reverse $INPUT_SOURCE $INPUT_DESTINATION; quit"