diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml index d6a1360..b814e9b 100644 --- a/.gitea/workflows/build.yml +++ b/.gitea/workflows/build.yml @@ -3,7 +3,7 @@ run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀 on: [push] jobs: - build-and-deploy: + build-and-deploy-to-local-server: runs-on: ubuntu-latest env: HUGO_VERSION: '0.147.5' @@ -22,9 +22,18 @@ jobs: - run: echo "💡 The ${{ gitea.repository }} repository has been cloned to the runner." - name: Build with Hugo run: hugo - - name: Deploy + - name: Local Deploy run: | rm -rf /workspace/html/blog mkdir -p /workspace/html/blog cp -r public/* /workspace/html/blog/ - - run: echo "🍏 This job's status is ${{ job.status }}." \ No newline at end of file + - run: echo "🍏 This job's status is ${{ job.status }}." + + deploy-to-remote-server: + needs: build-and-deploy-to-local-server + runs-on: mac + steps: + - name: Deploy to remote server + run: | + ssh root@1970666.xyz "rm -rf /root/docker/docker-nginx/html/blog" + scp -r /Users/konjacpotato/Workspace/docker/docker-nginx/html/blog root@1970666.xyz:/root/docker/docker-nginx/html/ \ No newline at end of file diff --git a/hugo.yaml b/hugo.yaml index b45a5bc..c7fd6c3 100644 --- a/hugo.yaml +++ b/hugo.yaml @@ -1,4 +1,4 @@ -baseURL: https://example.org/ +baseURL: https://1970666.xyz/ languageCode: zh-cn title: 魔芋土豆 theme: ["PaperMod"]