-
Notifications
You must be signed in to change notification settings - Fork 23
/
deploy.sh
executable file
·32 lines (28 loc) · 1009 Bytes
/
deploy.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/bin/bash
echo "Begin deploy of the Mozilla Change Integration Service version 2."
echo "$CODEBUILD_WEBHOOK_TRIGGER"
make login-to-ecr
make install-serverless
if [[ "branch/master" == "$CODEBUILD_WEBHOOK_TRIGGER" ]]
then
echo "Deploying the development environment."
make build STAGE=development
make publish STAGE=development
make release-no-docker STAGE=development
elif [[ "$CODEBUILD_WEBHOOK_TRIGGER" =~ ^tag\/[0-9]\.[0-9]\.[0-9](\-(pre|testing))?$ ]]
then
echo "Deploying the testing environment."
make build STAGE=testing
make publish STAGE=testing
make release-no-docker STAGE=testing
elif [[ "$CODEBUILD_WEBHOOK_TRIGGER" =~ ^tag\/[0-9]\.[0-9]\.[0-9](\-(prod))?$ ]]
then
echo "Deploying the production environment."
make build STAGE=production
make publish STAGE=production
make release-no-docker STAGE=production
fi
make build-ci-container
make push-ci-container
echo "$CODEBUILD_WEBHOOK_TRIGGER"
echo "End deploy of the Mozilla Change Integration Service version 2."