Skip to content

Commit d99fd5d

Browse files
CARRY: Add workflow run for auto-merge sync
1 parent 760f3cf commit d99fd5d

File tree

1 file changed

+41
-0
lines changed

1 file changed

+41
-0
lines changed
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
# Workflow is meant to run in the red-hat-data-services/codeflare-operator repo
2+
name: Auto-Merge-Sync
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
trigger-auto-merge-sync:
8+
runs-on: ubuntu-latest
9+
steps:
10+
- name: upstream-odh-auto-merge
11+
run: |
12+
gh workflow run upstream-auto-merge.yaml --repo github.com/red-hat-data-services/rhods-devops-infra --ref main --field repositories=codeflare-upstream
13+
sleep 5
14+
run_id=$(gh run list --workflow upstream-auto-merge.yaml --repo github.com/red-hat-data-services/rhods-devops-infra --limit 1 --json databaseId --jq .[].databaseId)
15+
gh run watch ${run_id} --repo github.com/red-hat-data-services/rhods-devops-infra --interval 10 --exit-status
16+
env:
17+
GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }}
18+
shell:
19+
bash
20+
- name: odh-rhds-auto-merge
21+
if: ${{ success()}}
22+
run: |
23+
gh workflow run upstream-auto-merge.yaml --repo github.com/red-hat-data-services/rhods-devops-infra --ref main --field repositories=codeflare-downstream
24+
sleep 5
25+
run_id=$(gh run list --workflow upstream-auto-merge.yaml --repo github.com/red-hat-data-services/rhods-devops-infra --limit 1 --json databaseId --jq .[].databaseId)
26+
gh run watch ${run_id} --repo github.com/red-hat-data-services/rhods-devops-infra --interval 10 --exit-status
27+
env:
28+
GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }}
29+
shell:
30+
bash
31+
- name: rhds-release-auto-merge
32+
if: ${{ success()}}
33+
run: |
34+
gh workflow run main-release-auto-merge.yaml --repo github.com/red-hat-data-services/rhods-devops-infra --ref main --field repositories=codeflare-operator
35+
sleep 5
36+
run_id=$(gh run list --workflow main-release-auto-merge.yaml --repo github.com/red-hat-data-services/rhods-devops-infra --limit 1 --json databaseId --jq .[].databaseId)
37+
gh run watch ${run_id} --repo github.com/red-hat-data-services/rhods-devops-infra --interval 10 --exit-status
38+
env:
39+
GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }}
40+
shell:
41+
bash

0 commit comments

Comments
 (0)