Skip to content

Commit

Permalink
Update demo config every time, and use STDIN
Browse files Browse the repository at this point in the history
  • Loading branch information
pmac committed May 3, 2017
1 parent 7a2148d commit 320e90e
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions docker/bin/demo_deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,17 @@ else
fi

echo "Creating the demo app $DEIS_APP_NAME"
if $DEIS_BIN apps:create "$DEIS_APP_NAME" --no-remote; then
echo "Configuring the new demo app"
$DEIS_BIN config:push -a "$DEIS_APP_NAME" -p docker/envfiles/demo.env || true
# Sentry DSN is potentially sensitive. Turn off command echo.
set +x
if [[ -n "$SENTRY_DEMO_DSN" ]]; then
$DEIS_BIN config:set -a "$DEIS_APP_NAME" "SENTRY_DSN=$SENTRY_DEMO_DSN" || true
fi
set -x
$DEIS_BIN apps:create "$DEIS_APP_NAME" --no-remote || true

echo "Configuring the new demo app"
$DEIS_BIN config:set -a "$DEIS_APP_NAME" $(< docker/envfiles/demo.env) || true

# Sentry DSN is potentially sensitive. Turn off command echo.
set +x
if [[ -n "$SENTRY_DEMO_DSN" ]]; then
$DEIS_BIN config:set -a "$DEIS_APP_NAME" "SENTRY_DSN=$SENTRY_DEMO_DSN" || true
fi
set -x

echo "Pulling $DOCKER_IMAGE_TAG into Deis app $DEIS_APP_NAME"
$DEIS_BIN pull "$DOCKER_IMAGE_TAG" -a "$DEIS_APP_NAME"

0 comments on commit 320e90e

Please sign in to comment.