Create Release PR #50
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Create Release PR | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| branchName: | |
| description: 'Branch name containing the changes' | |
| required: true | |
| type: string | |
| releaseVersion: | |
| description: 'Version being released' | |
| required: true | |
| type: string | |
| imageName: | |
| description: 'Docker image name' | |
| required: true | |
| type: string | |
| sourceRepo: | |
| description: 'Source repository that triggered this workflow' | |
| required: true | |
| type: string | |
| actor: | |
| description: 'User who triggered the release' | |
| required: true | |
| type: string | |
| concurrency: | |
| group: release-pr-${{ inputs.branchName }} | |
| cancel-in-progress: false | |
| jobs: | |
| create_pr: | |
| name: Create Release PR | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 5 | |
| permissions: | |
| pull-requests: write | |
| contents: read | |
| steps: | |
| - name: Checkout release branch | |
| uses: actions/checkout@v5 | |
| with: | |
| ref: ${{ inputs.branchName }} | |
| - name: Create Pull Request | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| run: | | |
| gh pr create \ | |
| --base main \ | |
| --head "${{ inputs.branchName }}" \ | |
| --title "Release [${{ inputs.imageName }} - ${{ inputs.releaseVersion }}] to production" \ | |
| --body "## Automated Deployment PR | |
| ### Details | |
| | Field | Value | | |
| |-------|-------| | |
| | **Environment** | Prod | | |
| | **Source Repository** | ${{ inputs.sourceRepo }} | | |
| | **Image** | \`${{ inputs.imageName }}\` | | |
| | **Version** | \`${{ inputs.releaseVersion }}\` | | |
| | **Triggered by** | @${{ inputs.actor }} | | |
| ### Review Checklist | |
| - [ ] Image built and pushed successfully | |
| - [ ] Source changes reviewed and approved | |
| --- | |
| **Merging this PR will trigger ArgoCD to sync the new image.**" |