Skip to content

Commit

Permalink
Merge pull request #338 from adorsys/cd-refactor
Browse files Browse the repository at this point in the history
fix(workflow): updated cd
  • Loading branch information
Christiantyemele authored Feb 26, 2025
2 parents 2ac173a + 1fccfca commit 7ee6f4c
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/CD.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ jobs:
docker tag $IMAGE_NAME $IMAGE_ID:$VERSION
docker push $IMAGE_ID:$VERSION
# Export the IMAGE_ID and VERSION as environment variables
echo "IMAGE_ID=$IMAGE_ID" >> $GITHUB_ENV
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: Install kubectl
if: github.ref == 'refs/heads/main' # Only run if the branch is main
uses: azure/setup-kubectl@v3
Expand All @@ -66,4 +70,4 @@ jobs:
- name: Update Kubernetes deployment
if: github.ref == 'refs/heads/main' # Only run if the branch is main
run: |
kubectl set image deployment/mediator-deployment mediator-container=$IMAGE_ID:$VERSION -n ${{ env.NAMESPACE }}
kubectl set image deployment/mediator-deployment mediator-container=${{ env.IMAGE_ID }}:${{ env.VERSION }} -n ${{ env.NAMESPACE }}

0 comments on commit 7ee6f4c

Please sign in to comment.