try different workflow setup
All checks were successful
Build Hugo Site / build (push) Successful in 12s

This commit is contained in:
John 2025-03-08 22:19:26 -06:00
parent c53a9efc04
commit 41b19efd30

View File

@ -14,24 +14,29 @@ jobs:
uses: actions/checkout@v4 uses: actions/checkout@v4
- name: Install Hugo - name: Install Hugo
run: | uses: peaceiris/actions-hugo@v2
apt update with:
apt install -y hugo hugo-version: 'latest'
- name: Build Hugo Site - name: Ensure Output Directory Exists
run: |
mkdir -p /data/hugo/public
chmod -R 777 /data/hugo/public
- name: Debug Working Directory
run: | run: |
# Print working directory for debugging
pwd pwd
ls -la ls -la
find . -name "hugo.toml"
# Navigate to Hugo site directory if it's in a subdirectory hugo config
cd /data/git/repositories/john/hugo
# Build directly to the mounted public directory - name: Build Hugo Site
hugo --minify -d /data/hugo/public working-directory: /workspace/john/hugo-blog
run: |
hugo --minify -d /data/hugo/public --config hugo.toml
# Verify the build was successful # Verify the build was successful
if [ ! -d /data/hugo/public ]; then if [ ! -d /data/hugo/public ]; then
echo "Hugo build failed - public directory not created" echo "Hugo build failed - public directory not created"
exit 1 exit 1
fi fi