buildspec.

This commit is contained in:
Bryce Covert
2020-09-10 15:07:57 -07:00
parent b003e785ea
commit f98d73d1d8

View File

@@ -6,15 +6,18 @@ phases:
docker: 19 docker: 19
pre_build: pre_build:
commands: commands:
- echo Logging in to Amazon ECR... - echo Logging in to Amazon ECR...
- aws --version - aws --version
- $(aws ecr get-login --region $AWS_DEFAULT_REGION --no-include-email) - $(aws ecr get-login --region $AWS_DEFAULT_REGION --no-include-email)
- REPOSITORY_URI=679918342773.dkr.ecr.us-east-1.amazonaws.com/integreat - REPOSITORY_URI=679918342773.dkr.ecr.us-east-1.amazonaws.com/integreat
- COMMIT_HASH=$(echo $CODEBUILD_RESOLVED_SOURCE_VERSION | cut -c 1-7) - COMMIT_HASH=$(echo $CODEBUILD_RESOLVED_SOURCE_VERSION | cut -c 1-7)
- IMAGE_TAG=${COMMIT_HASH:=latest} - IMAGE_TAG=${COMMIT_HASH:=latest}
- wget https://raw.github.com/technomancy/leiningen/stable/bin/lein
- chmod +x lein
build: build:
commands: commands:
- lein build - ./lein build
- echo Build started on `date` - echo Build started on `date`
- echo Building the Docker image... - echo Building the Docker image...
- docker build -t $REPOSITORY_URI:latest . - docker build -t $REPOSITORY_URI:latest .