forked from aptos-labs/aptos-core
-
Notifications
You must be signed in to change notification settings - Fork 0
/
buildspec.yaml
28 lines (26 loc) · 881 Bytes
/
buildspec.yaml
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
# This buildspec is for AWS Codebuild
version: 0.2
env:
secrets-manager:
DOCKERHUB_USERNAME: dockerhub_ro_username
DOCKERHUB_PASSWORD: dockerhub_ro_password
phases:
install:
runtime-versions:
docker: 18
pre_build:
commands:
- echo logging in to dockerhub.
- echo "$DOCKERHUB_PASSWORD" | docker login -u "$DOCKERHUB_USERNAME" --password-stdin
build:
commands:
- echo Build started on `date`
- echo Building the Docker image...
- bash docker/forge/build.sh
post_build:
commands:
- echo Build completed on `date`
# Tag and push the docker images
- echo Logging in to Amazon ECR...
- $(aws ecr get-login --no-include-email --region us-west-2)
- SOURCE=aptos/forge:latest TARGET_REPO=$APTOS_FORGE_REPO TARGET_TAGS="${TAGS}:dev_$(git rev-parse --short=8 HEAD)" docker/tag-and-push.sh