2024-04-29 17:18:42 +00:00
|
|
|
name: Deploy pages
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
deploy:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
2024-04-29 17:20:20 +00:00
|
|
|
- name: Setup Go
|
|
|
|
uses: actions/setup-go@v5
|
|
|
|
with:
|
|
|
|
go-version: "1.22.x"
|
2024-05-02 16:34:57 +00:00
|
|
|
- uses: https://code.icb4dc0.de/prskr/setup-hugo@main
|
2024-04-29 17:31:56 +00:00
|
|
|
with:
|
2024-05-02 16:34:57 +00:00
|
|
|
dart-sass: true
|
2024-11-27 19:51:16 +00:00
|
|
|
with-deploy: true
|
2024-04-29 17:31:56 +00:00
|
|
|
- uses: actions/cache@v4
|
|
|
|
with:
|
|
|
|
path: /home/runner/.cache/hugo_cache
|
|
|
|
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }}
|
|
|
|
restore-keys: |
|
|
|
|
${{ runner.os }}-hugomod-
|
2024-05-07 16:19:49 +00:00
|
|
|
- name: Build & deploy
|
2024-04-29 17:20:20 +00:00
|
|
|
run: |
|
|
|
|
hugo mod get
|
|
|
|
hugo --minify --environment production
|
2024-05-07 16:19:49 +00:00
|
|
|
hugo deploy
|
|
|
|
env:
|
2024-11-26 21:12:59 +00:00
|
|
|
AWS_ACCESS_KEY_ID: ${{ secrets.HCLOUD_KEY_ID }}
|
|
|
|
AWS_SECRET_ACCESS_KEY: ${{ secrets.HCLOUD_SECRET_KEY }}
|