Charts Values Seed Trigger Dispatcher #110
This file contains 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 of the Workflow | |
name: Charts Values Seed Trigger Dispatcher | |
on: | |
workflow_run: | |
workflows: | |
- "Java CI with Maven" | |
branches: | |
- master | |
- beta | |
types: | |
- completed | |
jobs: | |
charts-release-dispatcher: | |
name: Dispatch | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
repo: ['atlanhq/atlan'] | |
if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
steps: | |
# extract branch name | |
- name: Get branch name | |
id: extract_branch | |
run: | | |
echo "branch=${{ github.event.workflow_run.head_branch }}" >> $GITHUB_OUTPUT | |
- name: Extract Repository Name | |
id: extract_repo_name | |
run: | | |
repo_name=$(basename $GITHUB_REPOSITORY) | |
echo "repo_name=${repo_name}" >> $GITHUB_OUTPUT | |
- name: Repository Dispatch | |
uses: peter-evans/repository-dispatch@v2 | |
with: | |
token: ${{ secrets.my_pat }} | |
repository: ${{ matrix.repo }} | |
event-type: dispatch_chart_release_workflow | |
client-payload: |- | |
{ | |
"repo": { | |
"name": "${{ steps.extract_repo_name.outputs.repo_name }}", | |
"branch": "${{ steps.extract_branch.outputs.branch }}" | |
} | |
} |