forked from mozilla/bedrock
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Disable circle demo deploy * Add IRC notification to Jenkinsfile deployments * Fix the deployment docs for new pipeline
- Loading branch information
Showing
8 changed files
with
101 additions
and
91 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,49 +1,6 @@ | ||
#!/bin/bash | ||
set -ex | ||
|
||
DOCKER_CACHE_PATH=~/docker | ||
DOCKER_CACHE_FILE="${DOCKER_CACHE_PATH}/image.tgz" | ||
|
||
mkdir -p $DOCKER_CACHE_PATH | ||
make clean | ||
|
||
if [[ -f $DOCKER_CACHE_FILE ]]; then | ||
gunzip -c "$DOCKER_CACHE_FILE" | docker load; | ||
fi | ||
|
||
if [[ -f $DOCKER_CACHE_PATH/bedrock.db ]]; then | ||
mv $DOCKER_CACHE_PATH/bedrock.db ./ | ||
fi | ||
|
||
LOCALES_TAR_FILE="$DOCKER_CACHE_PATH/locales.tgz" | ||
if [[ -f "$LOCALES_TAR_FILE" ]]; then | ||
tar xzf "$LOCALES_TAR_FILE" | ||
rm -f "$LOCALES_TAR_FILE" | ||
fi | ||
|
||
MFSA_TAR_FILE="$DOCKER_CACHE_PATH/mfsa_repo.tgz" | ||
if [[ -f "$MFSA_TAR_FILE" ]]; then | ||
tar xzf "$MFSA_TAR_FILE" | ||
rm -f "$MFSA_TAR_FILE" | ||
fi | ||
|
||
PD_TAR_FILE="$DOCKER_CACHE_PATH/pd_files.tgz" | ||
if [[ -f "$PD_TAR_FILE" ]]; then | ||
tar xzf "$PD_TAR_FILE" | ||
rm -f "$PD_TAR_FILE" | ||
fi | ||
|
||
if [[ "$CIRCLE_BRANCH" == demo__* ]]; then | ||
make sync-all | ||
cp bedrock.db $DOCKER_CACHE_PATH/ | ||
tar czf "$LOCALES_TAR_FILE" locale | ||
tar czf "$MFSA_TAR_FILE" mofo_security_advisories | ||
if [[ -d product_details_json ]]; then | ||
tar czf "$PD_TAR_FILE" product_details_json | ||
fi | ||
fi | ||
|
||
echo "ENV GIT_SHA ${CIRCLE_SHA1}" >> docker/dockerfiles/bedrock_dev_final | ||
make build-final | ||
docker save $(docker history -q bedrock_dev_final | grep -v '<missing>') | gzip > $DOCKER_CACHE_FILE | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
#!/bin/bash | ||
set -ex | ||
|
||
DEIS_APP_NAME="bedrock-demo-${BRANCH_NAME#demo__}" | ||
# convert underscores to dashes. Deis does _not_ like underscores. | ||
DEIS_APP_NAME=$( echo "$DEIS_APP_NAME" | tr "_" "-" ) | ||
# used for pulling from deis | ||
DOCKER_IMAGE_TAG="${DEIS_APP_NAME}:${GIT_COMMIT}" | ||
# used for pushing to registry | ||
PRIVATE_IMAGE_TAG="${PRIVATE_REGISTRY}/${DOCKER_IMAGE_TAG}" | ||
|
||
docker tag "bedrock_dev_final:${GIT_COMMIT}" "$PRIVATE_IMAGE_TAG" | ||
docker push "$PRIVATE_IMAGE_TAG" | ||
|
||
echo "Creating the demo app $DEIS_APP_NAME" | ||
if deis apps:create "$DEIS_APP_NAME" --no-remote; then | ||
echo "Configuring the new demo app" | ||
deis config:push -a "$DEIS_APP_NAME" -p docker/demo.env | ||
# Sentry DSN is potentially sensitive. Turn off command echo. | ||
set +x | ||
if [[ -n "$SENTRY_DEMO_DSN" ]]; then | ||
deis config:set -a "$DEIS_APP_NAME" "SENTRY_DSN=$SENTRY_DEMO_DSN" | ||
fi | ||
set -x | ||
fi | ||
echo "Pulling $DOCKER_IMAGE_TAG into Deis app $DEIS_APP_NAME" | ||
deis pull "$DOCKER_IMAGE_TAG" -a "$DEIS_APP_NAME" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters