1
1

Add skip-base-image flag.

This commit is contained in:
Derek Smith 2023-04-07 10:57:54 -04:00
parent 42a22f4942
commit 8ec3af6703
Signed by: farscapian
GPG Key ID: B443E530A14E1C90
2 changed files with 10 additions and 3 deletions

View File

@ -35,8 +35,10 @@ if lxc remote get-default | grep -q "production"; then
fi fi
PRIMARY_DOMAIN= PRIMARY_DOMAIN=
RUN_CERT_RENEWAL=true RUN_CERT_RENEWAL=true
SKIP_BASE_IMAGE_CREATION=false
SKIP_WWW=false SKIP_WWW=false
RESTORE_WWW=false RESTORE_WWW=false
RESTORE_CERTS=false RESTORE_CERTS=false
@ -101,6 +103,10 @@ for i in "$@"; do
SKIP_BTCPAY=true SKIP_BTCPAY=true
shift shift
;; ;;
--skip-base-image)
SKIP_BASE_IMAGE_CREATION=true
shift
;;
--no-cert-renew) --no-cert-renew)
RUN_CERT_RENEWAL=false RUN_CERT_RENEWAL=false
shift shift
@ -303,7 +309,9 @@ VPS_HOSTNAME=
if ! lxc image list --format csv | grep -q "$DOCKER_BASE_IMAGE_NAME"; then if ! lxc image list --format csv | grep -q "$DOCKER_BASE_IMAGE_NAME"; then
# create the lxd base image. # create the lxd base image.
./create_lxc_base.sh if [ "$SKIP_BASE_IMAGE_CREATION" = false ]; then
./create_lxc_base.sh
fi
fi fi
for VIRTUAL_MACHINE in www btcpayserver; do for VIRTUAL_MACHINE in www btcpayserver; do
@ -322,7 +330,6 @@ for VIRTUAL_MACHINE in www btcpayserver; do
export SITE_PATH="$SITES_PATH/$DOMAIN_NAME" export SITE_PATH="$SITES_PATH/$DOMAIN_NAME"
source ./project/project_defaults.sh
source "$SITE_PATH/site.conf" source "$SITE_PATH/site.conf"
source ./project/domain_env.sh source ./project/domain_env.sh

View File

@ -77,7 +77,7 @@ git checkout "$GIT_COMMIT_ON_REMOTE_HOST"
cd - cd -
# run deploy which backups up everything, but doesnt restart any services. # run deploy which backups up everything, but doesnt restart any services.
bash -c "./deploy.sh --stop --backup-archive-path=$BTCPAY_RESTORE_ARCHIVE_PATH --backup-www --backup-btcpayserver" bash -c "./deploy.sh --stop --backup-archive-path=$BTCPAY_RESTORE_ARCHIVE_PATH --backup-www --backup-btcpayserver --skip-base-image"
# call the down script (be default it is non-destructuve of user data.) # call the down script (be default it is non-destructuve of user data.)
./down.sh ./down.sh