Skip to content

Commit

Permalink
CI: updated flow to run build image and deploy only on release branches
Browse files Browse the repository at this point in the history
  • Loading branch information
karthik1729 committed Dec 16, 2023
1 parent 592d8e4 commit e931c2e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion .github/workflows/build-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,11 @@ jobs:
echo "BRANCH_TAG=$(echo ${GITHUB_REF#refs/heads/} | sed 's/\//-/g')" >> $GITHUB_ENV
- name: Build & Push Image
if: startsWith(github.ref, 'refs/heads/release')
run: |
original_string=${{GITHUB_REF}}
version_string="v${original_string#release-}-nightly"
cd .github/workflows/container-build
task go-container-build Image="ghcr.io/kloudlite/platform/apis/${{matrix.app}}:${{env.BRANCH_TAG}}"
task go-container-build Image="ghcr.io/kloudlite/platform/apis/${{matrix.app}}:$version_string"
task go-container-build Image="ghcr.io/kloudlite/platform/apis/${{matrix.app}}:commit-${GITHUB_SHA}"

0 comments on commit e931c2e

Please sign in to comment.