forked from vectordotdev/vector
-
Notifications
You must be signed in to change notification settings - Fork 0
431 lines (381 loc) · 17.3 KB
/
integration.yml
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
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
# Integration Test Suite
#
# This workflow runs the integration tests. If the workflow is triggered in the merge queue, all integration tests
# are run. If the workflow is triggered in a PR commit, then the files changed in the PR are evaluated to determine
# if any integration tests will run.
name: Integration Test Suite
on:
pull_request:
merge_group:
types: [checks_requested]
concurrency:
# `github.event.number` exists for pull requests, otherwise fall back to SHA for merge queue
group: ${{ github.workflow }}-${{ github.event.number || github.event.merge_group.head_sha }}
cancel-in-progress: true
env:
AWS_ACCESS_KEY_ID: "dummy"
AWS_SECRET_ACCESS_KEY: "dummy"
CONTAINER_TOOL: "docker"
DD_ENV: "ci"
DD_API_KEY: ${{ secrets.DD_API_KEY }}
TEST_DATADOG_API_KEY: ${{ secrets.CI_TEST_DATADOG_API_KEY }}
TEST_APPSIGNAL_PUSH_API_KEY: ${{ secrets.TEST_APPSIGNAL_PUSH_API_KEY }}
AXIOM_TOKEN: ${{ secrets.AXIOM_TOKEN }}
RUST_BACKTRACE: full
TEST_LOG: vector=debug
VERBOSE: true
CI: true
PROFILE: debug
# observing issues fetching boringssl via HTTPS in the OSX build, seeing if this helps
# can be removed when we switch back to the upstream openssl-sys crate
CARGO_NET_GIT_FETCH_WITH_CLI: true
jobs:
changes:
if: github.event_name == 'pull_request'
uses: ./.github/workflows/changes.yml
with:
base_ref: ${{ github.event.pull_request.base.ref }}
head_ref: ${{ github.event.pull_request.head.ref }}
source: false
int_tests: true
secrets: inherit
integration-tests:
name: Integration Tests
runs-on: ubuntu-20.04-4core
needs: changes
if: always() && (
github.event_name == 'merge_group' || (
needs.changes.outputs.all-int == 'true'
|| needs.changes.outputs.amqp == 'true'
|| needs.changes.outputs.appsignal == 'true'
|| needs.changes.outputs.aws == 'true'
|| needs.changes.outputs.axiom == 'true'
|| needs.changes.outputs.azure == 'true'
|| needs.changes.outputs.clickhouse == 'true'
|| needs.changes.outputs.databend == 'true'
|| needs.changes.outputs.datadog-agent == 'true'
|| needs.changes.outputs.datadog-logs == 'true'
|| needs.changes.outputs.datadog-metrics == 'true'
|| needs.changes.outputs.datadog-traces == 'true'
|| needs.changes.outputs.dnstap == 'true'
|| needs.changes.outputs.docker-logs == 'true'
|| needs.changes.outputs.elasticsearch == 'true'
|| needs.changes.outputs.eventstoredb == 'true'
|| needs.changes.outputs.fluent == 'true'
|| needs.changes.outputs.gcp == 'true'
|| needs.changes.outputs.greptimedb == 'true'
|| needs.changes.outputs.humio == 'true'
|| needs.changes.outputs.http-client == 'true'
|| needs.changes.outputs.influxdb == 'true'
|| needs.changes.outputs.kafka == 'true'
|| needs.changes.outputs.logstash == 'true'
|| needs.changes.outputs.loki == 'true'
|| needs.changes.outputs.mongodb == 'true'
|| needs.changes.outputs.nats == 'true'
|| needs.changes.outputs.nginx == 'true'
|| needs.changes.outputs.opentelemetry == 'true'
|| needs.changes.outputs.postgres == 'true'
|| needs.changes.outputs.prometheus == 'true'
|| needs.changes.outputs.pulsar == 'true'
|| needs.changes.outputs.redis == 'true'
|| needs.changes.outputs.splunk == 'true'
|| needs.changes.outputs.webhdfs == 'true'
)
)
timeout-minutes: 90
steps:
- uses: actions/checkout@v4
with:
submodules: "recursive"
- run: sudo npm -g install @datadog/datadog-ci
- run: docker image prune -af ; docker container prune -f
- name: Determine if secrets are defined (PR author is team member).
if: github.event_name == 'pull_request'
env:
GH_APP_DATADOG_VECTOR_CI_APP_ID: ${{ secrets.GH_APP_DATADOG_VECTOR_CI_APP_ID }}
run: |
if [[ "$GH_APP_DATADOG_VECTOR_CI_APP_ID" != "" ]] ; then
echo "PR_HAS_ACCESS_TO_SECRETS=true" >> "$GITHUB_ENV"
else
echo "PR_HAS_ACCESS_TO_SECRETS=false" >> "$GITHUB_ENV"
fi
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.amqp == 'true' }}
name: amqp
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int amqp
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.appsignal == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: appsignal
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int appsignal
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.aws == 'true' }}
name: aws
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int aws
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.axiom == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: axiom
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int axiom
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.azure == 'true' }}
name: azure
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int azure
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.clickhouse == 'true' }}
name: clickhouse
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int clickhouse
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.databend == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: databend
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int databend
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.datadog-agent == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: datadog-agent
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int datadog-agent
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.datadog-logs == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: datadog-logs
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int datadog-logs
- run: docker image prune -af --filter=label!=vector-test-runner=true ; docker container prune -f
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.datadog-metrics == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: datadog-metrics
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int datadog-metrics
- if: (github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.datadog-traces == 'true') &&
(github.event_name != 'pull_request' || env.PR_HAS_ACCESS_TO_SECRETS == 'true')
name: datadog-traces
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int datadog-traces
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.dnstap == 'true' }}
name: dnstap
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int dnstap
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.docker-logs == 'true' }}
name: docker-logs
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int docker-logs
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.elasticsearch == 'true' }}
name: elasticsearch
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int elasticsearch
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.eventstoredb == 'true' }}
name: eventstoredb
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int eventstoredb
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.fluent == 'true' }}
name: fluent
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int fluent
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.gcp == 'true' }}
name: gcp
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int gcp
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.greptimedb == 'true' }}
name: greptimedb
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int greptimedb
- run: docker image prune -af --filter=label!=vector-test-runner=true ; docker container prune -f
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.humio == 'true' }}
name: humio
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int humio
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.http-client == 'true' }}
name: http-client
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int http-client
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.influxdb == 'true' }}
name: influxdb
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int influxdb
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.kafka == 'true' }}
name: kafka
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int kafka
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.logstash == 'true' }}
name: logstash
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int logstash
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.loki == 'true' }}
name: loki
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int loki
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.mongodb == 'true' }}
name: mongodb
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int mongodb
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.mqtt == 'true' }}
name: mqtt
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int mqtt
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.nats == 'true' }}
name: nats
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int nats
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.nginx == 'true' }}
name: nginx
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int nginx
- run: docker image prune -af --filter=label!=vector-test-runner=true ; docker container prune -f
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.opentelemetry == 'true' }}
name: opentelemetry
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int opentelemetry
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.postgres == 'true' }}
name: postgres
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int postgres
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.prometheus == 'true' }}
name: prometheus
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int prometheus
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.pulsar == 'true' }}
name: pulsar
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int pulsar
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.redis == 'true' }}
name: redis
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int redis
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' }}
name: shutdown
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int shutdown
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.splunk == 'true' }}
name: splunk
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int splunk
- if: ${{ github.event_name == 'merge_group' || needs.changes.outputs.all-int == 'true' || needs.changes.outputs.webhdfs == 'true' }}
name: webhdfs
uses: nick-fields/retry@v3
with:
timeout_minutes: 30
max_attempts: 3
command: bash scripts/ci-int-e2e-test.sh int webhdfs
integration-test-suite:
name: Integration Test Suite
runs-on: ubuntu-latest
timeout-minutes: 5
if: always()
needs:
- changes
- integration-tests
env:
FAILED: ${{ contains(needs.*.result, 'failure') }}
steps:
- run: |
echo "failed=${{ env.FAILED }}"
if [[ "$FAILED" == "true" ]] ; then
exit 1
else
exit 0
fi