fixes deploy image and adds debugging
Some checks failed
build-and-deploy / build (push) Has been cancelled
Some checks failed
build-and-deploy / build (push) Has been cancelled
This commit is contained in:
@ -9,15 +9,24 @@ jobs:
|
|||||||
build:
|
build:
|
||||||
runs-on: 'lightsail-runner'
|
runs-on: 'lightsail-runner'
|
||||||
container:
|
container:
|
||||||
image: klakegg/hugo:0.121.1-ext-ubuntu
|
image: klakegg/hugo:ext
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout code
|
- name: Checkout code
|
||||||
uses: actions/checkout@v3
|
uses: actions/checkout@v3
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Environment Info
|
||||||
|
run: |
|
||||||
|
hugo version
|
||||||
|
pwd
|
||||||
|
ls -la
|
||||||
|
|
||||||
- name: Build site
|
- name: Build site
|
||||||
run: hugo --minify
|
run: |
|
||||||
|
hugo --minify --debug
|
||||||
|
echo "Build completed, checking output:"
|
||||||
|
ls -la public/
|
||||||
env:
|
env:
|
||||||
HUGO_ENV: production
|
HUGO_ENV: production
|
||||||
|
|
||||||
@ -28,7 +37,16 @@ jobs:
|
|||||||
|
|
||||||
- name: Install and Deploy with Surfer
|
- name: Install and Deploy with Surfer
|
||||||
run: |
|
run: |
|
||||||
|
echo "Node version: $(node --version)"
|
||||||
|
echo "NPM version: $(npm --version)"
|
||||||
npm install -g cloudron-surfer
|
npm install -g cloudron-surfer
|
||||||
|
echo "Deploying to server: ${{ secrets.SURFER_SERVER }}"
|
||||||
|
echo "Files to deploy:"
|
||||||
|
ls -la public/
|
||||||
if ! surfer put --token ${{ secrets.SURFER_TOKEN }} --server ${{ secrets.SURFER_SERVER }} public/* /; then
|
if ! surfer put --token ${{ secrets.SURFER_TOKEN }} --server ${{ secrets.SURFER_SERVER }} public/* /; then
|
||||||
echo "Deployment failed"
|
echo "Deployment failed with status $?"
|
||||||
exit 1
|
echo "Current directory contents:"
|
||||||
|
ls -la
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
echo "Deployment completed successfully"
|
Reference in New Issue
Block a user