Skip to content

Commit

Permalink
Update ci.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
stevensrtw authored Sep 19, 2024
1 parent a2b6ba8 commit bc153d0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,8 @@ jobs:
--domain-owner $AWS_ACCOUNT_ID \
--region $AWS_REGION \
--query authorizationToken \
--output text)
--output text) > codeartifcact-auth
export CODEARTIFACT_AUTH_TOKEN=$(cat codeartifcact-auth)
# Get token from ECR and Docker login
aws ecr get-login-password --region $AWS_REGION | docker login --username AWS --password-stdin ${{ secrets.AWS_ACCOUNT_ID }}.dkr.ecr.$AWS_REGION.amazonaws.com
Expand All @@ -47,7 +48,7 @@ jobs:
REGISTRY=201959883603.dkr.ecr.us-east-2.amazonaws.com

# Build the Docker image
docker build --build-arg CODEARTIFACT_AUTH_TOKEN=$GET_CODEARTIFACT_AUTH_TOKEN -f Dockerfile-mvn-no-local -t $REGISTRY/$REPOSITORY:$IMAGE_TAG .
docker build --build-arg CODEARTIFACT_AUTH_TOKEN=$CODEARTIFACT_AUTH_TOKEN -f Dockerfile-mvn-no-local -t $REGISTRY/$REPOSITORY:$IMAGE_TAG .

# Push the Docker image
docker push $REGISTRY/$REPOSITORY:$IMAGE_TAG
Expand Down

0 comments on commit bc153d0

Please sign in to comment.