WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Commit 559d279

Browse files
authored
[8.19] (backport #18386) Backport smart exhaustive tests (#18389)
1 parent a4740ed commit 559d279

File tree

3 files changed

+147
-21
lines changed

3 files changed

+147
-21
lines changed

.buildkite/pull-requests.json

Lines changed: 65 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,66 @@
11
{
2-
"jobs": [
3-
{
4-
"enabled": true,
5-
"pipeline_slug": "logstash-pull-request-pipeline",
6-
"allow_org_users": true,
7-
"allowed_repo_permissions": ["admin", "write"],
8-
"allowed_list": ["dependabot[bot]", "mergify[bot]", "github-actions[bot]", "elastic-vault-github-plugin-prod[bot]"],
9-
"set_commit_status": true,
10-
"build_on_commit": true,
11-
"build_on_comment": true,
12-
"trigger_comment_regex": "^(?:(?:buildkite\\W+)?(?:build|test)\\W+(?:this|it))",
13-
"always_trigger_comment_regex": "^(?:(?:buildkite\\W+)?(?:build|test)\\W+(?:this|it))",
14-
"skip_ci_labels": [ ],
15-
"skip_target_branches": [ ],
16-
"skip_ci_on_only_changed": [
17-
"^docs/"
18-
],
19-
"always_require_ci_on_changed": [ ]
20-
}
21-
]
22-
}
2+
"jobs": [
3+
{
4+
"enabled": true,
5+
"pipeline_slug": "logstash-pull-request-pipeline",
6+
"allow_org_users": true,
7+
"allowed_repo_permissions": [
8+
"admin",
9+
"write"
10+
],
11+
"allowed_list": [
12+
"dependabot[bot]",
13+
"mergify[bot]",
14+
"github-actions[bot]",
15+
"elastic-vault-github-plugin-prod[bot]"
16+
],
17+
"set_commit_status": true,
18+
"build_on_commit": true,
19+
"build_on_comment": true,
20+
"trigger_comment_regex": "^(?:(?:buildkite\\W+)?(?:build|test)\\W+(?:this|it))",
21+
"always_trigger_comment_regex": "^(?:(?:buildkite\\W+)?(?:build|test)\\W+(?:this|it))",
22+
"skip_ci_labels": [],
23+
"skip_target_branches": [],
24+
"skip_ci_on_only_changed": [
25+
"^.github/",
26+
"^docs/",
27+
"^.mergify.yml$",
28+
"^.pre-commit-config.yaml",
29+
"\\.md$"
30+
],
31+
"always_require_ci_on_changed": []
32+
},
33+
{
34+
"enabled": true,
35+
"pipeline_slug": "logstash-smart-exhaustive-tests-pipeline",
36+
"allow_org_users": true,
37+
"allowed_repo_permissions": [
38+
"admin",
39+
"write"
40+
],
41+
"allowed_list": [
42+
"dependabot[bot]",
43+
"mergify[bot]",
44+
"github-actions[bot]"
45+
],
46+
"set_commit_status": true,
47+
"build_on_commit": true,
48+
"build_on_comment": true,
49+
"trigger_comment_regex": "^run\\s+exhaustive\\s+tests$",
50+
"always_trigger_comment_regex": "^run\\s+exhaustive\\s+tests$",
51+
"skip_ci_labels": [],
52+
"skip_target_branches": [],
53+
"skip_ci_on_only_changed": [
54+
"^.github/",
55+
"^docs/",
56+
"^.mergify.yml$",
57+
"^.pre-commit-config.yaml",
58+
"\\.md$"
59+
],
60+
"always_require_ci_on_changed": [
61+
"^qa/acceptance/",
62+
"^ci/acceptance_tests.sh"
63+
]
64+
}
65+
]
66+
}
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
steps:
2+
- label: "Trigger logstash-exhaustive-tests-pipeline for PRs with qa/acceptance/ changes"
3+
if: build.pull_request.id != null && build.env("GITHUB_PR_TRIGGER_COMMENT") != "run exhaustive tests"
4+
plugins:
5+
- monorepo-diff#v1.0.1:
6+
diff: "git diff --name-only origin/${GITHUB_PR_TARGET_BRANCH}...HEAD"
7+
interpolation: false
8+
watch:
9+
- path:
10+
- ^qa/acceptance/
11+
- ^ci/acceptance_tests.sh
12+
- .buildkite/smart_exhaustive_tests_pipeline.yml
13+
config:
14+
trigger: "logstash-exhaustive-tests-pipeline"
15+
build:
16+
commit: "${BUILDKITE_COMMIT}"
17+
branch: "${BUILDKITE_BRANCH}"
18+
env:
19+
BUILDKITE_PULL_REQUEST: "${BUILDKITE_PULL_REQUEST}"
20+
BUILDKITE_PULL_REQUEST_BASE_BRANCH: "${BUILDKITE_PULL_REQUEST_BASE_BRANCH}"
21+
ELASTIC_SLACK_NOTIFICATIONS_ENABLED: false
22+
23+
- label: "Trigger logstash-exhaustive-tests-pipeline for GitHub comments"
24+
if: build.env("GITHUB_PR_TRIGGER_COMMENT") == "run exhaustive tests"
25+
trigger: "logstash-exhaustive-tests-pipeline"
26+
build:
27+
commit: "HEAD"
28+
branch: "pull/${BUILDKITE_PULL_REQUEST}/merge"
29+
env:
30+
BUILDKITE_PULL_REQUEST: "${BUILDKITE_PULL_REQUEST}"
31+
ELASTIC_SLACK_NOTIFICATIONS_ENABLED: false

catalog-info.yaml

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -476,6 +476,57 @@ spec:
476476
# SECTION END: Exhaustive tests pipeline
477477
# **************************************
478478

479+
# ****************************************
480+
# SECTION START: Smart exhaustive tests pipeline
481+
# ****************************************
482+
483+
---
484+
# yaml-language-server: $schema=https://gist.githubusercontent.com/elasticmachine/988b80dae436cafea07d9a4a460a011d/raw/rre.schema.json
485+
apiVersion: backstage.io/v1alpha1
486+
kind: Resource
487+
metadata:
488+
name: logstash-smart-exhaustive-tests-pipeline
489+
description: 'Logstash Smart Exhaustive tests pipeline'
490+
links:
491+
- title: 'Logstash Smart Exhaustive tests pipeline'
492+
url: https://buildkite.com/elastic/logstash-smart-exhaustive-tests-pipeline
493+
spec:
494+
type: buildkite-pipeline
495+
owner: group:logstash
496+
system: platform-ingest
497+
implementation:
498+
apiVersion: buildkite.elastic.dev/v1
499+
kind: Pipeline
500+
metadata:
501+
name: "Logstash Smart Exhaustive tests pipeline"
502+
description: '🔍 Run smart exhaustive tests against Logstash using different operating systems'
503+
spec:
504+
repository: elastic/logstash
505+
pipeline_file: ".buildkite/smart_exhaustive_tests_pipeline.yml"
506+
provider_settings:
507+
build_pull_request_forks: false
508+
build_pull_requests: true # requires filter_enabled and filter_condition settings as below when used with buildkite-pr-bot
509+
build_branches: false
510+
build_tags: false
511+
filter_enabled: true
512+
filter_condition: >-
513+
build.creator.name == 'elasticmachine' && build.pull_request.id != null
514+
cancel_intermediate_builds: true
515+
skip_intermediate_builds: true
516+
teams:
517+
ingest-fp:
518+
access_level: MANAGE_BUILD_AND_READ
519+
logstash:
520+
access_level: MANAGE_BUILD_AND_READ
521+
ingest-eng-prod:
522+
access_level: MANAGE_BUILD_AND_READ
523+
everyone:
524+
access_level: READ_ONLY
525+
526+
# **************************************
527+
# SECTION END: Smart exhaustive tests pipeline
528+
# **************************************
529+
479530
# ********************************************
480531
# Declare supported plugin tests pipeline
481532
# ********************************************

0 commit comments

Comments
 (0)