File tree Expand file tree Collapse file tree 1 file changed +33
-0
lines changed
Expand file tree Collapse file tree 1 file changed +33
-0
lines changed Original file line number Diff line number Diff line change 1+ version : 0.2
2+
3+ env :
4+ variables :
5+ AWS_REGION : " us-west-1"
6+ REACT_APP_API_SERVICE_URL : " http://localhost:5004"
7+
8+ phases :
9+ pre_build :
10+ commands :
11+ - echo logging in to ecr...
12+ - >
13+ aws ecr get-login-password --region $AWS_REGION \
14+ | docker login --username AWS --password-stdin $AWS_ACCOUNT_ID.dkr.ecr.$AWS_REGION.amazonaws.com
15+ build :
16+ commands :
17+ - echo building images...
18+ - >
19+ docker build \
20+ -f services/users/Dockerfile.prod \
21+ -t $AWS_ACCOUNT_ID.dkr.ecr.$AWS_REGION.amazonaws.com/test-driven-users:prod \
22+ ./services/users
23+ - >
24+ docker build \
25+ -f services/client/Dockerfile.prod \
26+ -t $AWS_ACCOUNT_ID.dkr.ecr.$AWS_REGION.amazonaws.com/test-driven-client:prod \
27+ --build-arg NODE_ENV=production \
28+ --build-arg REACT_APP_API_SERVICE_URL=$REACT_APP_API_SERVICE_URL \
29+ ./services/client
30+ post_build :
31+ commands :
32+ - docker push $AWS_ACCOUNT_ID.dkr.ecr.$AWS_REGION.amazonaws.com/test-driven-users:prod
33+ - docker push $AWS_ACCOUNT_ID.dkr.ecr.$AWS_REGION.amazonaws.com/test-driven-client:prod
You can’t perform that action at this time.
0 commit comments