Add github actions, minify output
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
This commit is contained in:
parent
05b1d9836f
commit
3ad6083d81
29
.github/workflows/main.yml
vendored
Normal file
29
.github/workflows/main.yml
vendored
Normal file
|
@ -0,0 +1,29 @@
|
|||
name: Hugo
|
||||
on: [push]
|
||||
permissions:
|
||||
contents: read
|
||||
pages: write
|
||||
id-token: write
|
||||
jobs:
|
||||
build:
|
||||
runs-on: git.korhonen.cc/functionalhacker/hugo-asciidoc-docker-ci:latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
- run: npm install
|
||||
- run: hugo --gc --minify --cleanDestinationDir -d /korhonen.cc
|
||||
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
needs: build
|
||||
steps:
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-pages-artifact@v2
|
||||
with:
|
||||
path: './public'
|
||||
- name: Deploy to GitHub Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v2
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
|
@ -3,7 +3,7 @@ steps:
|
|||
image: git.korhonen.cc/functionalhacker/hugo-asciidoc-docker-ci:latest
|
||||
commands:
|
||||
- npm install
|
||||
- hugo --gc --cleanDestinationDir -d /korhonen.cc
|
||||
- hugo --gc --minify --cleanDestinationDir -d /korhonen.cc
|
||||
volumes:
|
||||
- /var/www/korhonen.cc:/korhonen.cc
|
||||
environment:
|
||||
|
|
Loading…
Reference in a new issue