custom deploy [ci skip] #7
@ -17,3 +17,7 @@ HUGO_GIT_URL=git@codeberg.org:eotl/example-repo.git
|
|||||||
#COMPOSE_FILE="$COMPOSE_FILE:compose.private.yml"
|
#COMPOSE_FILE="$COMPOSE_FILE:compose.private.yml"
|
||||||
#PRIVATE_ENABLED=1
|
#PRIVATE_ENABLED=1
|
||||||
#SECRET_DEPLOY_KEY_VERSION=v1
|
#SECRET_DEPLOY_KEY_VERSION=v1
|
||||||
|
|
||||||
|
# Custom deployment script
|
||||||
|
#CUSTOM_DEPLOY_ENABLED=1
|
||||||
|
#CUSTOM_DEPLOY_SCRIPT=path/customscript.sh
|
||||||
|
@ -31,6 +31,8 @@ services:
|
|||||||
badger:
|
badger:
|
||||||
image: codeberg.org/eotl/site-badger:0.1.0
|
image: codeberg.org/eotl/site-badger:0.1.0
|
||||||
environment:
|
environment:
|
||||||
|
- CUSTOM_DEPLOY_ENABLED
|
||||||
|
- CUSTOM_DEPLOY_SCRIPT
|
||||||
- HUGO_GIT_URL
|
- HUGO_GIT_URL
|
||||||
- HUGO_GIT_BRANCH
|
- HUGO_GIT_BRANCH
|
||||||
- HUGO_PUBLIC_DIR=/usr/share/nginx/website
|
- HUGO_PUBLIC_DIR=/usr/share/nginx/website
|
||||||
|
@ -29,6 +29,11 @@ if [ ! -z "$HUGO_GIT_BRANCH" ]; then
|
|||||||
git checkout origin/$HUGO_GIT_BRANCH
|
git checkout origin/$HUGO_GIT_BRANCH
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [ "$CUSTOM_DEPLOY_ENABLED" == "1" ]; then
|
||||||
|
echo "◆ Executing custom deploy script: $HUGO_WORKING_DIR/$CUSTOM_DEPLOY_SCRIPT"
|
||||||
|
bash $HUGO_WORKING_DIR/$CUSTOM_DEPLOY_SCRIPT
|
||||||
|
fi
|
||||||
|
|
||||||
echo "◆ Install or update Hugo Modules"
|
echo "◆ Install or update Hugo Modules"
|
||||||
|
|
||||||
hugo mod get -u
|
hugo mod get -u
|
||||||
|
Reference in New Issue
Block a user