-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuildspec.yml
31 lines (26 loc) · 869 Bytes
/
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
version: 0.2
env:
secrets-manager:
DOCKER_HUB_USERNAME: "/demo/shared/docker-hub/credentials:username"
DOCKER_HUB_PASSWORD: "/demo/shared/docker-hub/credentials:password"
# env:
# variables:
# CI_SERVICE_IMAGE_REPOSITORY_URL: 123456789123.dkr.ecr.eu-central-1.amazonaws.com/services
# CI_SERVICE_URL_TYPE: 'path'
phases:
install:
runtime-versions:
nodejs: 20
commands:
- sh -c "$(curl --location https://taskfile.dev/install.sh)" -- -d v3.38.0
- mv ./bin/task /usr/local/bin/task && chmod +x /usr/local/bin/task
pre_build:
commands:
# - export AWS_ECR_ACCOUNT_ID=$AWS_ACCOUNT_ID
# - export AWS_ECR_REGION=$AWS_DEFAULT_REGION
- export GIT_COMMIT=${CODEBUILD_RESOLVED_SOURCE_VERSION}
- task docker:login
- task docker:login-ecr
build:
commands:
- task docker:build-push