Skip to content

Commit

Permalink
Update cd.yml
Browse files Browse the repository at this point in the history
Signed-off-by: Md Imran <imranaec@outlook.com>
  • Loading branch information
narmidm committed Oct 18, 2024
1 parent 29e9ebf commit 83c870c
Showing 1 changed file with 8 additions and 3 deletions.
11 changes: 8 additions & 3 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,22 @@ jobs:
VERSION=${GITHUB_REF##*/}
echo "VERSION=$VERSION" >> $GITHUB_ENV
# Step 5: Build and Tag Docker Image
# Step 5: Build Docker Image
- name: Build Docker Image
run: |
# Build Docker image
docker build -t narmidm/k8stoolbox:latest -f docker/Dockerfile .
# Tag the Docker image with the release version
docker tag narmidm/k8stoolbox:latest narmidm/k8stoolbox:${{ env.VERSION }}
# Step 6: Push Docker Image
# Step 6: Push Docker Image with Latest and Version Tags
- name: Push Docker Image
run: |
# Push Docker image with latest and version tags
# Ensure the image is built and tagged successfully
docker images
# Push Docker image with latest tag
docker push narmidm/k8stoolbox:latest
# Push Docker image with version tag
docker push narmidm/k8stoolbox:${{ env.VERSION }}

0 comments on commit 83c870c

Please sign in to comment.