-
Notifications
You must be signed in to change notification settings - Fork 123
245 lines (243 loc) · 9.19 KB
/
check-extended.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
name: check-extended
on:
issue_comment:
types:
- created
jobs:
prepare-env:
runs-on:
group: infra1-runners-arc
labels: runners-small
permissions: read-all
outputs:
branch: ${{ steps.branch.outputs.branch }}
ref: refs/pull/${{ github.event.issue.number }}/merge
commit: ${{ steps.commit.outputs.commit }}
pr_number: ${{ github.event.issue.number }}
project: ${{ github.repository }}
changed_files: ${{ steps.changed-files.outputs.all_changed_files }}
steps:
- name: Branch name
id: branch
run: |-
branch=$(echo "${{ github.ref }}" | sed 's/^refs\/heads\///')
echo "branch=$branch" >> "$GITHUB_OUTPUT"
- name: Commit
id: commit
run: |-
pr_head_sha=$(curl -s -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \
"https://api.github.com/repos/${{ github.repository }}/pulls/${{ github.event.issue.number }}" | \
jq --raw-output .head.sha)
echo "commit=$pr_head_sha" >> "$GITHUB_OUTPUT"
- uses: actions/checkout@v4
with:
ref: refs/pull/${{ github.event.issue.number }}/merge
- name: Get changed files
id: changed-files
uses: tj-actions/changed-files@v40
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
gooddata-ruby-integration-tests-zuul:
runs-on:
group: infra1-runners-arc
labels: runners-small
needs:
- prepare-env
permissions:
contents: read
id-token: write
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
steps:
- name: Call Jenkins trigger
id: call-jenkins
uses: gooddata/github-actions-public/jenkins/trigger@master
with:
server: ${{ secrets.JENKINS_ADDRESS }}
folder: lcm
job-name: gooddata-ruby-integration-tests-zuul
vault-url: ${{ secrets.VAULT_ADDRESS }}
params: |-
{
"GH_BRANCH": "${{ needs.prepare-env.outputs.branch }}",
"GH_REF": "${{ needs.prepare-env.outputs.ref }}",
"GH_COMMIT": "${{ needs.prepare-env.outputs.commit }}",
"GH_URL": "[email protected]:",
"GH_CHANGE": "${{ needs.prepare-env.outputs.pr_number }}",
"GH_PROJECT": "${{ needs.prepare-env.outputs.project }}",
"BUILD_BY_GITHUB": "true",
"GH_PIPELINE": "check-extended"
}
comment-pr: 'true'
gooddata-lcm-ruby-integration-e2e-zuul:
runs-on:
group: infra1-runners-arc
labels: runners-small
needs:
- prepare-env
permissions:
contents: read
id-token: write
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
steps:
- name: Call Jenkins trigger
id: call-jenkins
uses: gooddata/github-actions-public/jenkins/trigger@master
with:
server: ${{ secrets.JENKINS_ADDRESS }}
folder: lcm
job-name: gooddata-lcm-ruby-integration-e2e-zuul
vault-url: ${{ secrets.VAULT_ADDRESS }}
params: |-
{
"GH_BRANCH": "${{ needs.prepare-env.outputs.branch }}",
"GH_REF": "${{ needs.prepare-env.outputs.ref }}",
"GH_COMMIT": "${{ needs.prepare-env.outputs.commit }}",
"GH_URL": "[email protected]:",
"GH_CHANGE": "${{ needs.prepare-env.outputs.pr_number }}",
"GH_PROJECT": "${{ needs.prepare-env.outputs.project }}",
"BUILD_BY_GITHUB": "true",
"GH_PIPELINE": "check-extended"
}
comment-pr: 'true'
gooddata-lcm-ruby-integration-release-zuul:
runs-on:
group: infra1-runners-arc
labels: runners-small
needs:
- prepare-env
permissions:
contents: read
id-token: write
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
steps:
- name: Call Jenkins trigger
id: call-jenkins
uses: gooddata/github-actions-public/jenkins/trigger@master
with:
server: ${{ secrets.JENKINS_ADDRESS }}
folder: lcm
job-name: gooddata-lcm-ruby-integration-release-zuul
vault-url: ${{ secrets.VAULT_ADDRESS }}
params: |-
{
"GH_BRANCH": "${{ needs.prepare-env.outputs.branch }}",
"GH_REF": "${{ needs.prepare-env.outputs.ref }}",
"GH_COMMIT": "${{ needs.prepare-env.outputs.commit }}",
"GH_URL": "[email protected]:",
"GH_CHANGE": "${{ needs.prepare-env.outputs.pr_number }}",
"GH_PROJECT": "${{ needs.prepare-env.outputs.project }}",
"BUILD_BY_GITHUB": "true",
"GH_PIPELINE": "check-extended"
}
comment-pr: 'true'
gooddata-lcm-ruby-integration-others-zuul:
runs-on:
group: infra1-runners-arc
labels: runners-small
needs:
- prepare-env
permissions:
contents: read
id-token: write
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
steps:
- name: Call Jenkins trigger
id: call-jenkins
uses: gooddata/github-actions-public/jenkins/trigger@master
with:
server: ${{ secrets.JENKINS_ADDRESS }}
folder: lcm
job-name: gooddata-lcm-ruby-integration-others-zuul
vault-url: ${{ secrets.VAULT_ADDRESS }}
params: |-
{
"GH_BRANCH": "${{ needs.prepare-env.outputs.branch }}",
"GH_REF": "${{ needs.prepare-env.outputs.ref }}",
"GH_COMMIT": "${{ needs.prepare-env.outputs.commit }}",
"GH_URL": "[email protected]:",
"GH_CHANGE": "${{ needs.prepare-env.outputs.pr_number }}",
"GH_PROJECT": "${{ needs.prepare-env.outputs.project }}",
"BUILD_BY_GITHUB": "true",
"GH_PIPELINE": "check-extended"
}
comment-pr: 'true'
gooddata-lcm-ruby-integration-slow-zuul:
runs-on:
group: infra1-runners-arc
labels: runners-small
needs:
- prepare-env
permissions:
contents: read
id-token: write
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
steps:
- name: Call Jenkins trigger
id: call-jenkins
uses: gooddata/github-actions-public/jenkins/trigger@master
with:
server: ${{ secrets.JENKINS_ADDRESS }}
folder: lcm
job-name: gooddata-lcm-ruby-integration-slow-zuul
vault-url: ${{ secrets.VAULT_ADDRESS }}
params: |-
{
"GH_BRANCH": "${{ needs.prepare-env.outputs.branch }}",
"GH_REF": "${{ needs.prepare-env.outputs.ref }}",
"GH_COMMIT": "${{ needs.prepare-env.outputs.commit }}",
"GH_URL": "[email protected]:",
"GH_CHANGE": "${{ needs.prepare-env.outputs.pr_number }}",
"GH_PROJECT": "${{ needs.prepare-env.outputs.project }}",
"BUILD_BY_GITHUB": "true",
"GH_PIPELINE": "check-extended"
}
comment-pr: 'true'
gooddata-lcm-ruby-integration-userprov-zuul:
runs-on:
group: infra1-runners-arc
labels: runners-small
needs:
- prepare-env
permissions:
contents: read
id-token: write
if: ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
steps:
- name: Call Jenkins trigger
id: call-jenkins
uses: gooddata/github-actions-public/jenkins/trigger@master
with:
server: ${{ secrets.JENKINS_ADDRESS }}
folder: lcm
job-name: gooddata-lcm-ruby-integration-userprov-zuul
vault-url: ${{ secrets.VAULT_ADDRESS }}
params: |-
{
"GH_BRANCH": "${{ needs.prepare-env.outputs.branch }}",
"GH_REF": "${{ needs.prepare-env.outputs.ref }}",
"GH_COMMIT": "${{ needs.prepare-env.outputs.commit }}",
"GH_URL": "[email protected]:",
"GH_CHANGE": "${{ needs.prepare-env.outputs.pr_number }}",
"GH_PROJECT": "${{ needs.prepare-env.outputs.project }}",
"BUILD_BY_GITHUB": "true",
"GH_PIPELINE": "check-extended"
}
comment-pr: 'true'
ready-to-merge:
runs-on:
group: infra1-runners-arc
labels: runners-small
if: always() && ${{ github.event.issue.pull_request && startsWith(github.event.comment.body, 'extended test') }}
needs:
- prepare-env
- gooddata-ruby-integration-tests-zuul
- gooddata-lcm-ruby-integration-e2e-zuul
- gooddata-lcm-ruby-integration-release-zuul
- gooddata-lcm-ruby-integration-others-zuul
- gooddata-lcm-ruby-integration-slow-zuul
- gooddata-lcm-ruby-integration-userprov-zuul
steps:
- name: Check if needed jobs succeeded
uses: re-actors/alls-green@release/v1
with:
allowed-skips: ${{ toJSON(needs) }}
jobs: ${{ toJSON(needs) }}