Skip to content

Commit 2cf723f

Browse files
committed
Say "the FTP login was rejected" when that is what happened
The guard that verifies the deploy target reported every curl failure as "could not list the FTP login directory, so the target is unverified". That reads like a network problem or a wrong path, so two runs went looking at the wrong thing -- the actual cause both times was curl exit 67, which means the server rejected the username and password. Now exit 67 gets its own message naming the cause and the three places to fix it. Everything else keeps the old wording, which is right for it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0128YzbhrfGdegUSc9RrARRf
1 parent 9b7e275 commit 2cf723f

1 file changed

Lines changed: 21 additions & 1 deletion

File tree

‎.github/workflows/deploy-hostinger.yml‎

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,27 @@ jobs:
103103
set -e
104104
105105
if [ "$rc" -ne 0 ]; then
106-
echo "::error::Could not list the FTP login directory, so the target is unverified."
106+
# curl exit 67 is specifically "the server rejected the login", and
107+
# saying so is worth the six lines: the generic message sent two
108+
# runs chasing the wrong thing, because "could not list the
109+
# directory" reads like a network or path problem when it is
110+
# actually a username and password the host no longer accepts.
111+
if [ "$rc" -eq 67 ]; then
112+
echo "::error::The FTP server rejected the username and password."
113+
echo ""
114+
echo "The three secrets are set, they are just no longer valid --"
115+
echo "an account renamed, deleted, or its password changed."
116+
echo ""
117+
echo " 1. hPanel -> Files -> FTP Accounts: note the hostname and"
118+
echo " username, and set a new password if you do not have it."
119+
echo " 2. Check the account's directory is the website root, the"
120+
echo " folder holding index.html. This deploy writes to"
121+
echo " wherever the account lands when it logs in."
122+
echo " 3. Update FTP_SERVER, FTP_USERNAME and FTP_PASSWORD under"
123+
echo " Settings -> Secrets and variables -> Actions."
124+
else
125+
echo "::error::Could not list the FTP login directory, so the target is unverified."
126+
fi
107127
sed 's/^/ /' "$cfg.err" | head -5
108128
exit 1
109129
fi

0 commit comments

Comments
 (0)