Merge branch 'feat/initial-build' into main
Some checks failed
ci / build-test (push) Successful in 3m55s
deploy / build (push) Successful in 28s
deploy / deploy (push) Failing after 12s

Fix lftp auth (explicit -u USER, + unindented heredoc body).
This commit is contained in:
hsiegeln
2026-04-24 20:08:29 +02:00

View File

@@ -118,10 +118,18 @@ jobs:
: "${SFTP_USER:?SFTP_USER secret must be set}" : "${SFTP_USER:?SFTP_USER secret must be set}"
: "${SFTP_HOST:?SFTP_HOST secret must be set}" : "${SFTP_HOST:?SFTP_HOST secret must be set}"
: "${SFTP_PATH:?SFTP_PATH secret must be set}" : "${SFTP_PATH:?SFTP_PATH secret must be set}"
# `-u USER,` (with trailing comma = empty password) tells lftp not
# to prompt for a password; auth happens via the key passed to ssh
# by sftp:connect-program. Heredoc body is unindented so lftp's
# parser doesn't mistake leading whitespace for a continuation.
# `debug 3` prints the ssh command lftp invokes — useful if this
# ever breaks again.
lftp <<LFTP lftp <<LFTP
debug 3
set cmd:fail-exit yes set cmd:fail-exit yes
set net:max-retries 1
set sftp:connect-program 'ssh -a -x -i $HOME/.ssh/id_ed25519 -o StrictHostKeyChecking=yes -o UserKnownHostsFile=$HOME/.ssh/known_hosts' set sftp:connect-program 'ssh -a -x -i $HOME/.ssh/id_ed25519 -o StrictHostKeyChecking=yes -o UserKnownHostsFile=$HOME/.ssh/known_hosts'
open sftp://$SFTP_USER@$SFTP_HOST open -u $SFTP_USER, sftp://$SFTP_HOST
mirror --reverse --delete --verbose --parallel=4 dist/ $SFTP_PATH/ mirror --reverse --delete --verbose --parallel=4 dist/ $SFTP_PATH/
bye bye
LFTP LFTP