File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 77 description : ' RHOAI version to process (e.g. rhoai-3.5, rhoai-3.5-ea.2). Branch name used if omitted.'
88 required : false
99 type : string
10+ dry_run :
11+ description : ' Push results to BRANCH-dry-run instead of the actual branch.'
12+ required : false
13+ type : boolean
14+ default : false
1015 push :
1116 paths :
1217 - bundle/additional-images-patch.yaml
@@ -160,6 +165,8 @@ jobs:
160165 git config user.name "Openshift-AI DevOps"
161166 git config user.email "openshift-ai-devops@redhat.com"
162167 git add -A
168+ PUSH_BRANCH="${{ inputs.dry_run == true && format('{0}-dry-run-bundle', steps.get_branch.outputs.branch) || steps.get_branch.outputs.branch }}"
169+ FORCE_FLAG="${{ inputs.dry_run == true && '--force' || '' }}"
163170 git diff --staged --quiet || (git commit -m "Updating the bundle-csv and helm chart values with latest images
164171
165- ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" && git push origin ${{ steps.get_branch.outputs.branch } })
172+ ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" && git push ${FORCE_FLAG} origin HEAD:${PUSH_BRANCH })
Original file line number Diff line number Diff line change 77 description : ' RHOAI version to process (e.g. rhoai-3.5, rhoai-3.5-ea.2). Branch name used if omitted.'
88 required : false
99 type : string
10+ dry_run :
11+ description : ' Push results to BRANCH-dry-run instead of the actual branch.'
12+ required : false
13+ type : boolean
14+ default : false
1015 push :
1116 paths :
1217 - schedule/bundle-github-trigger.txt
@@ -150,6 +155,8 @@ jobs:
150155 git config user.name "Openshift-AI DevOps"
151156 git config user.email "openshift-ai-devops@redhat.com"
152157 git add -A
158+ PUSH_BRANCH="${{ inputs.dry_run == true && format('{0}-dry-run-nightly-bundle', steps.get_branch.outputs.branch) || steps.get_branch.outputs.branch }}"
159+ FORCE_FLAG="${{ inputs.dry_run == true && '--force' || '' }}"
153160 git diff --staged --quiet || (git commit -m "Updating the bundle-csv and helm chart values with latest images
154161
155- ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" && git push origin ${{ steps.get_branch.outputs.branch } })
162+ ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" && git push ${FORCE_FLAG} origin HEAD:${PUSH_BRANCH })
You can’t perform that action at this time.
0 commit comments