From 8766d230cddc2e19fa10c1ae69a4fca50d81645f Mon Sep 17 00:00:00 2001 From: RaineAllDay Date: Wed, 18 Mar 2026 05:01:57 -0600 Subject: [PATCH] fixing deploy action... again --- .gitea/workflows/deploy.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index d85d68e..6cff8f3 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -58,17 +58,18 @@ jobs: steps: - name: Deploy via SSH run: | - # Write the private key to a temp file + # Write the private key mkdir -p ~/.ssh echo "${{ secrets.DEPLOY_SSH_KEY }}" > ~/.ssh/deploy_key chmod 600 ~/.ssh/deploy_key - # Disable strict host checking so first connection doesn't hang - echo "StrictHostKeyChecking no" >> ~/.ssh/config + # Pre-accept the host key so SSH doesn't hang waiting for input + ssh-keyscan -p ${{ secrets.DEPLOY_PORT }} ${{ secrets.DEPLOY_HOST }} >> ~/.ssh/known_hosts 2>/dev/null # SSH in and run the redeploy script ssh -i ~/.ssh/deploy_key \ -p ${{ secrets.DEPLOY_PORT }} \ + -o StrictHostKeyChecking=yes \ ${{ secrets.DEPLOY_USER }}@${{ secrets.DEPLOY_HOST }} \ "bash /opt/etc-prs/app/scripts/redeploy.sh"