Update workflow to use Hugo runner container instead of Docker commands
Build and deploy Hugo site / build (push) Has been cancelled
Build and deploy Hugo site / build (push) Has been cancelled
This commit is contained in:
@@ -3,7 +3,7 @@ on: [push]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: act_runner1
|
||||
runs-on: hugo:docker://192.168.8.254.5:5000/hugo:v0.163.3
|
||||
steps:
|
||||
- name: Checkout repository (shell)
|
||||
run: |
|
||||
@@ -26,23 +26,10 @@ jobs:
|
||||
fi
|
||||
fi
|
||||
|
||||
- name: Pull Hugo Docker image
|
||||
- name: Build site with Hugo
|
||||
run: |
|
||||
set -e
|
||||
IMAGE=192.168.254.5:5000/hugo:v0.163.3
|
||||
echo "Pulling $IMAGE"
|
||||
docker pull "$IMAGE"
|
||||
|
||||
- name: Build site with Hugo (Docker)
|
||||
run: |
|
||||
set -e
|
||||
IMAGE=192.168.254.5:5000/hugo:v0.163.3
|
||||
# Ensure public directory exists and is writable
|
||||
mkdir -p public
|
||||
docker run --rm \
|
||||
-v "$PWD":/src \
|
||||
-v "$PWD"/public:/target \
|
||||
"$IMAGE" hugo -s /src -d /target --minify
|
||||
hugo --minify
|
||||
|
||||
- name: Show generated files
|
||||
run: |
|
||||
|
||||
Reference in New Issue
Block a user