Skip to content

Commit

Permalink
Image name change
Browse files Browse the repository at this point in the history
  • Loading branch information
sureshhewabi committed Oct 3, 2023
1 parent d224ef3 commit 79631c9
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions .github/workflows/github.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,20 +38,16 @@ jobs:
password: ${{ secrets.GHCR_TOKEN }}

- name: Print variables
run: echo $GITHUB_REPOSITORY $IMAGE_NAME $GITHUB_SHA

- name: Read Docker Image Identifiers
run: echo ::set-env name=IMAGE_REPOSITORY::$(echo ${{ github.repository }} | tr '[:upper:]' '[:lower:]')

- name: Print variables again
run: echo ${{ env.IMAGE_REPOSITORY }}
run: cat ${{ vars.API_GITHUB_REPOSITORY }}

- name: Build and push Docker image
uses: docker/build-push-action@v2
with:
context: .
push: true
tags: ghcr.io/${{ env.IMAGE_REPOSITORY }}/$IMAGE_NAME:$GITHUB_SHA
tags: |
ghcr.io/${{ vars.API_GITHUB_REPOSITORY }}:latest
ghcr.io/${{ vars.API_GITHUB_REPOSITORY }}:${{ env.IMAGE_TAG }}
deploy:
needs: docker_build
Expand All @@ -70,7 +66,7 @@ jobs:
k8s_replicas: ${{ vars.K8S_REPLICAS }}
K8S_NAMESPACE: ${{ vars.K8S_NAMESPACE }}
DATABASE_INI: ${{ vars.DATABASE_INI }}
IMAGE: ghcr.io/$GITHUB_REPOSITORY/$IMAGE_NAME:$GITHUB_SHA
IMAGE: ghcr.io/${{ vars.API_GITHUB_REPOSITORY }}:latest

steps:
- name: Checkout repository
Expand Down

0 comments on commit 79631c9

Please sign in to comment.