Skip to content

Commit

Permalink
Fix tag variable for build job
Browse files Browse the repository at this point in the history
juffalow committed Aug 9, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
1 parent 247d2f5 commit 4798bc4
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -79,11 +79,14 @@ jobs:
- uses: actions/checkout@v2
with:
fetch-depth: 1
- name: Set variables
id: vars
run: echo ::set-output name=tag::${GITHUB_REF#refs/*/}
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ZDIELAJ_SI_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_ZDIELAJ_SI_SECRET_ACCESS_KEY }}
aws-access-key-id: ${{ secrets.AWS_GRAPHQL_JUFFALOW_COM_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_GRAPHQL_JUFFALOW_COM_SECRET_ACCESS_KEY }}
aws-region: ${{ secrets.AWS_CONTAINER_REGISTRY_REGION }}
- name: Login to Amazon ECR
id: login-ecr
@@ -92,7 +95,7 @@ jobs:
env:
REGISTRY: ${{ steps.login-ecr.outputs.registry }}
REPOSITORY: express-graphql-example
TAG: ${GITHUB_REF#"refs/tags/"}
TAG: ${{ steps.vars.outputs.tag }}
run: |
docker build -t $REGISTRY/$REPOSITORY:$TAG .
docker push $REGISTRY/$REPOSITORY:$TAG

0 comments on commit 4798bc4

Please sign in to comment.