diff --git a/.gitea/workflows/publish.yaml b/.gitea/workflows/publish.yaml index 1559e88..ec02106 100644 --- a/.gitea/workflows/publish.yaml +++ b/.gitea/workflows/publish.yaml @@ -9,10 +9,16 @@ jobs: build-and-deploy: runs-on: ubuntu-latest steps: + - name: Add SSH Key + run: | + echo "${{ secrets.SSH_KEY }}" > $HOME/.ssh/id_rsa + chmod 600 $HOME/.ssh/id_rsa + ssh-keyscan -H git.ericxliu.me >> $HOME/.ssh/known_hosts - name: Checkout code uses: actions/checkout@v4 with: + ssh-key: ${{ secrets.SSH_KEY }} persist-credentials: false submodules: true # Fetch Hugo themes (true OR recursive) fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod