forked from itteco/iframely
-
Notifications
You must be signed in to change notification settings - Fork 0
/
buildspec.yml
34 lines (34 loc) · 1.1 KB
/
buildspec.yml
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
33
34
version: 0.2
env:
variables:
PRX_ECR_CONFIG_PARAMETERS: "IframelyEcrImageTag"
PRX_SPIRE_ECR_PKG_PARAMETERS: WEB_SERVER=/prx/stag/Spire/The_World-Iframely/pkg/docker-image-tag
parameter-store:
DOCKERHUB_USERNAME: /prx/DOCKERHUB_USERNAME
DOCKERHUB_PASSWORD: /prx/DOCKERHUB_PASSWORD
exported-variables:
- PRX_ECR_CONFIG_PARAMETERS
- PRX_ECR_IMAGE
- PRX_SPIRE_ECR_PKG_PARAMETERS
- WEB_SERVER
phases:
install:
runtime-versions:
docker: 18
pre_build:
commands:
- echo Logging in to Docker Hub...
- echo $DOCKERHUB_PASSWORD | docker login --username $DOCKERHUB_USERNAME --password-stdin
build:
commands:
- echo CODEBUILD_BUILD_ID=$CODEBUILD_BUILD_ID > .env
- echo PRX_REPO=$PRX_REPO >> .env
- echo PRX_COMMIT=$PRX_COMMIT >> .env
- echo PRX_BRANCH=$PRX_BRANCH >> .env
- echo PRX_GITHUB_PR=$PRX_GITHUB_PR >> .env
- docker-compose build
post_build:
commands:
- curl -sO "https://raw.githubusercontent.com/PRX/Infrastructure/main/ci/utility/post_build.sh"
- chmod +x post_build.sh
- . ./post_build.sh