From d0a0747858dbacff87f50a96f06c453a015bfcb4 Mon Sep 17 00:00:00 2001 From: Ashaffah Date: Thu, 22 Feb 2024 10:16:23 +0700 Subject: [PATCH] Update Docker image build and push process --- .github/workflows/docker-image.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 91db9a2..021c29c 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -24,9 +24,9 @@ jobs: - name: Build and push Docker image run: | - docker build -t ashaffah/kodepos:${{ github.sha }} -t docker.pkg.github.com/${{ github.repository }}/kodepos:${{ github.sha }} . - docker push ashaffah/kodepos:${{ github.sha }} - docker push docker.pkg.github.com/${{ github.repository }}/kodepos:${{ github.sha }} + VERSION=$(git describe --tags --abbrev=0) + docker build -t ashaffah/kode-pos:$VERSION . + docker push ashaffah/kode-pos:$VERSION - name: Set latest version run: echo "LATEST_VERSION=latest" >> $GITHUB_ENV