ci: print runner-visible VPS host fingerprints

This commit is contained in:
Dhruv Sharma 2026-04-02 12:41:56 +05:30
parent 65e971349a
commit d0983913fc
1 changed files with 9 additions and 9 deletions

View File

@ -70,16 +70,16 @@ jobs:
echo "fetch_ref=main" >> "$GITHUB_OUTPUT"
echo "should_deploy=true" >> "$GITHUB_OUTPUT"
- name: Read VPS RSA host fingerprint
- name: Read runner-visible VPS host fingerprints
if: steps.resolve_deploy.outputs.print_host_rsa_fingerprint == 'true'
uses: appleboy/ssh-action@v1.2.2
with:
host: ${{ secrets.VPS_HOST }}
username: root
key: ${{ secrets.VPS_SSH_KEY }}
script: |
set -e
ssh-keygen -lf /etc/ssh/ssh_host_rsa_key.pub -E sha256 | awk '{print $2}'
env:
VPS_HOST: ${{ secrets.VPS_HOST }}
run: |
set -e
for type in rsa ecdsa ed25519; do
echo "==> $type"
ssh-keyscan -T 10 -t "$type" "$VPS_HOST" 2>/dev/null | ssh-keygen -lf - -E sha256
done
- name: Deploy via SSH
if: steps.resolve_deploy.outputs.should_deploy == 'true'