From 0c8f0ba037ec3ff367b1ac903acb2dbaa29a4c11 Mon Sep 17 00:00:00 2001 From: brookee Date: Thu, 29 Feb 2024 19:51:08 -0500 Subject: [PATCH] update --- .gitea/workflows/deploy.yaml | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/.gitea/workflows/deploy.yaml b/.gitea/workflows/deploy.yaml index b5792b2..8c3b996 100644 --- a/.gitea/workflows/deploy.yaml +++ b/.gitea/workflows/deploy.yaml @@ -9,20 +9,22 @@ jobs: steps: - uses: actions/checkout@v3 - with: - fetch-depth: 0 - submodules: recursive + - name: Add key + run: | + mkdir $HOME/.ssh && \ + echo "${{ secrets.SSH_PRIVATE_KEY }}" > $HOME/.ssh/id_rsa - name: Grab packages run: | apt-get update && \ apt-get install -y jq rsync tar wget && \ - wget https://github.com/gohugoio/hugo/releases/download/v0.123.4/hugo_extended_0.123.4_linux-amd64.tar.gz && \ - tar -xzvf hugo_extended_0.123.4_linux-amd64.tar.gz && \ - chmod +x hugo + wget https://github.com/gohugoio/hugo/releases/download/v0.123.4/hugo_0.123.4_linux-amd64.tar.gz && \ + tar -xzvf hugo_0.123.4_linux-amd64.tar.gz && \ + chmod +x hugo - name: Run build task run: ./hugo --minify --logLevel info + - name: Test static page + run: bash ${{ gitea.workspace }}/bin/test_static_page.sh - name: Deploy to Server - # run: rsync -avz --delete public/ ${{ vars.REMOTE_USER }}@${{ vars.REMOTE_HOST }}:${{ vars.REMOTE_TARGET }} uses: easingthemes/ssh-deploy@main env: SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}