This commit is contained in:
parent
23567fb978
commit
997080a31d
@ -18,25 +18,20 @@ jobs:
|
||||
with:
|
||||
hugo-version: 'latest'
|
||||
|
||||
- name: Ensure Output Directory Exists
|
||||
run: |
|
||||
mkdir -p /data/hugo/public
|
||||
chmod -R 777 /data/hugo/public
|
||||
|
||||
- name: Debug Working Directory
|
||||
run: |
|
||||
pwd
|
||||
ls -la
|
||||
find . -name "hugo.toml"
|
||||
hugo config
|
||||
echo "Current directory structure:"
|
||||
find . -type f
|
||||
|
||||
- name: Build Hugo Site
|
||||
working-directory: /workspace/john/hugo-blog
|
||||
run: |
|
||||
hugo --minify -d /data/hugo/public --config hugo.toml
|
||||
# Build directly in the workspace, then copy to the mounted volume
|
||||
hugo --minify
|
||||
|
||||
# Verify the build was successful
|
||||
if [ ! -d /data/hugo/public ]; then
|
||||
echo "Hugo build failed - public directory not created"
|
||||
exit 1
|
||||
fi
|
||||
# Copy the generated files to the mounted volume
|
||||
cp -r public/* /data/hugo/public/
|
||||
|
||||
# Verify the copy was successful
|
||||
ls -la /data/hugo/public/
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user