Update push.yml

This commit is contained in:
MattTheTekie 2023-12-30 15:24:35 -05:00 committed by GitHub
commit 6343ece0e7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -13,12 +13,13 @@ jobs:
- name: Checkout code
uses: actions/checkout@v2
- name: Getting Ready...
- name: Write SSH keys
run: |
echo "Getting Ready..."
mkdir -p ~/.ssh/
echo "HOST *" > ~/.ssh/config
echo "StrictHostKeyChecking no" >> ~/.ssh/config
install -m 600 -D /dev/null ~/.ssh/id_rsa
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa
host='host.example.com'
hosts="$(dig +short "$host" | grep -v '\.$' | sed -z 's|\n|,|g')$host"
ssh-keyscan -H "$hosts" > ~/.ssh/known_hosts
- name: Pushing Files...
run: |