diff --git a/.gitea/workflows/hugo-deploy.yaml b/.gitea/workflows/hugo-deploy.yaml new file mode 100644 index 0000000..53f6ac7 --- /dev/null +++ b/.gitea/workflows/hugo-deploy.yaml @@ -0,0 +1,30 @@ +# gitea/actions/hugo-deploy.yml +name: Deploy Hugo Site + +on: + push: + branches: + - main + +jobs: + build: + runs-on: ubuntu-latest + + steps: + - name: Clone Repository + uses: actions/checkout@v3 + + - name: Install Hugo + run: | + apt-get update + apt-get install -y hugo + + - name: Build Hugo Site + run: hugo --minify + + - name: Deploy to Hugo Container + run: | + rsync -avz --delete public/ /mnt/hugo/ + env: + HUGO_CONTAINER_PATH: /mnt/hugo/ + GITEA_RUNNER_MOUNT_PATH: ./hugo/public:/mnt/hugo \ No newline at end of file