Skip to content

Commit

Permalink
Merge release branch into master branch [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
Nubisproject (Mozilla) committed Jul 16, 2018
2 parents 634ca84 + e995fad commit 2eda93e
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion nubis-deploy
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,14 @@ setup-terraform () {
else
export ARENA
fi
ENVIRONMENT=$(json2hcl -reverse < "${MOUNT_TERRAFORM_PATH}/terraform.tfvars" | jq -r .environment )
# Make sure we got an arena
if [ "${ENVIRONMENT}" == 'null' ]; then
echo -e "\033[1;31mERROR: 'environment' not set ${MOUNT_TERRAFORM_PATH}/terraform.tfvars\033[0m"
exit 1
else
export ENVIRONMENT
fi
DEPLOYMENT_REGION=$(json2hcl -reverse < "${MOUNT_TERRAFORM_PATH}/terraform.tfvars" | jq -r .region )
# Make sure we got a deployment region
if [ "${DEPLOYMENT_REGION}" == 'null' ]; then
Expand Down Expand Up @@ -163,7 +171,7 @@ terraform-init () {
-input="${TTY_INPUT}" \
-upgrade=true \
-backend-config="region=${BUCKET_REGION}" \
-backend-config="key=terraform/${SERVICE_NAME}" \
-backend-config="key=terraform/${DEPLOYMENT_REGION}/${ARENA}/${ENVIRONMENT}/${SERVICE_NAME}" \
-backend-config="bucket=${STATE_BUCKET}"
then
echo -e "\033[1;31mERROR: Could not initialize teraform\033[0m"
Expand Down

0 comments on commit 2eda93e

Please sign in to comment.