🔊 Add consistent errors for env vars not set (#200)

This commit is contained in:
Sebastián Ramírez
2020-05-25 08:33:36 +02:00
committed by GitHub
parent 1a64656267
commit 20fa4ce8fb
6 changed files with 80 additions and 78 deletions

View File

@@ -3,7 +3,7 @@
# Exit in case of error
set -e
TAG=${TAG} \
TAG=${TAG?Variable not set} \
FRONTEND_ENV=${FRONTEND_ENV-production} \
sh ./scripts/build.sh

View File

@@ -3,7 +3,7 @@
# Exit in case of error
set -e
TAG=${TAG} \
TAG=${TAG?Variable not set} \
FRONTEND_ENV=${FRONTEND_ENV-production} \
docker-compose \
-f docker-compose.yml \

View File

@@ -3,14 +3,14 @@
# Exit in case of error
set -e
DOMAIN=${DOMAIN} \
TRAEFIK_TAG=${TRAEFIK_TAG} \
STACK_NAME=${STACK_NAME} \
TAG=${TAG} \
DOMAIN=${DOMAIN?Variable not set} \
TRAEFIK_TAG=${TRAEFIK_TAG?Variable not set} \
STACK_NAME=${STACK_NAME?Variable not set} \
TAG=${TAG?Variable not set} \
docker-compose \
-f docker-compose.yml \
config > docker-stack.yml
docker-auto-labels docker-stack.yml
docker stack deploy -c docker-stack.yml --with-registry-auth "${STACK_NAME}"
docker stack deploy -c docker-stack.yml --with-registry-auth "${STACK_NAME?Variable not set}"