add hugo deploy workflow
This commit is contained in:
24
.gitea/workflows/deploy-hugo.yaml
Normal file
24
.gitea/workflows/deploy-hugo.yaml
Normal file
@ -0,0 +1,24 @@
|
||||
name: Deploy Hugo Site
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: self-hosted
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Setup Hugo
|
||||
uses: peaceiris/actions-hugo@v2
|
||||
with:
|
||||
hugo-version: '0.147' # specify your Hugo version
|
||||
|
||||
- name: Build Hugo site
|
||||
run: hugo --destination /home/pim/website-live
|
||||
|
||||
- name: Sync to live
|
||||
run: rsync -av --delete ./public/ /home/pim/website-live/
|
||||
Reference in New Issue
Block a user