Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/plugin-mirror.yml
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,14 @@ jobs:
exit 0
fi
install -m 700 -d ~/.ssh
printf '%s\n' "$DEPLOY_KEY" > ~/.ssh/mirror_key
# A key pasted into the secret from Windows carries CRLF line ends,
# which OpenSSH refuses ("error in libcrypto").
printf '%s\n' "$DEPLOY_KEY" | tr -d '\r' > ~/.ssh/mirror_key
chmod 600 ~/.ssh/mirror_key
if ! ssh-keygen -y -f ~/.ssh/mirror_key > /dev/null; then
echo "::error::PLUGIN_MIRROR_DEPLOY_KEY is not a readable private key. Paste the whole private key file, from its BEGIN line to its END line."
exit 1
fi
ssh-keyscan github.com >> ~/.ssh/known_hosts 2>/dev/null
export GIT_SSH_COMMAND="ssh -i ~/.ssh/mirror_key -o IdentitiesOnly=yes"

Expand Down
Loading