From d3660f8b9121eb2364e770bccf8850e551f66f6e Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Tue, 26 Oct 2021 12:21:48 +0200 Subject: [PATCH] [CI]: use the downstream packaging pipeline for branches/tags (#28589) (cherry picked from commit ccc880e001a2cf55018143f86f17c58aa1b3cef1) --- auditbeat/Jenkinsfile.yml | 12 ++++++++++++ filebeat/Jenkinsfile.yml | 12 ++++++++++++ heartbeat/Jenkinsfile.yml | 12 ++++++++++++ journalbeat/Jenkinsfile.yml | 12 ++++++++++++ metricbeat/Jenkinsfile.yml | 12 ++++++++++++ packetbeat/Jenkinsfile.yml | 12 ++++++++++++ winlogbeat/Jenkinsfile.yml | 6 ++++++ x-pack/auditbeat/Jenkinsfile.yml | 12 ++++++++++++ x-pack/dockerlogbeat/Jenkinsfile.yml | 12 ++++++++++++ x-pack/elastic-agent/Jenkinsfile.yml | 15 ++++++++++++--- x-pack/filebeat/Jenkinsfile.yml | 12 ++++++++++++ x-pack/functionbeat/Jenkinsfile.yml | 6 ++++++ x-pack/heartbeat/Jenkinsfile.yml | 12 ++++++++++++ x-pack/metricbeat/Jenkinsfile.yml | 12 ++++++++++++ x-pack/osquerybeat/Jenkinsfile.yml | 6 ++++++ x-pack/packetbeat/Jenkinsfile.yml | 12 ++++++++++++ x-pack/winlogbeat/Jenkinsfile.yml | 6 ++++++ 17 files changed, 180 insertions(+), 3 deletions(-) diff --git a/auditbeat/Jenkinsfile.yml b/auditbeat/Jenkinsfile.yml index d4acba5b7cb4..ec64b4fc3d79 100644 --- a/auditbeat/Jenkinsfile.yml +++ b/auditbeat/Jenkinsfile.yml @@ -99,6 +99,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^auditbeat/.*" + - "@oss" ## special token regarding the changeset for the oss packaging-arm: packaging-arm: "mage package" e2e: @@ -106,3 +112,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^auditbeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/filebeat/Jenkinsfile.yml b/filebeat/Jenkinsfile.yml index 2e743e24ad5a..de591fc124ed 100644 --- a/filebeat/Jenkinsfile.yml +++ b/filebeat/Jenkinsfile.yml @@ -94,6 +94,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^filebeat/.*" + - "@oss" ## special token regarding the changeset for the oss packaging-arm: packaging-arm: "mage package" e2e: @@ -101,3 +107,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^filebeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/heartbeat/Jenkinsfile.yml b/heartbeat/Jenkinsfile.yml index ab0347b88109..2eeaf4864647 100644 --- a/heartbeat/Jenkinsfile.yml +++ b/heartbeat/Jenkinsfile.yml @@ -104,6 +104,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^heartbeat/.*" + - "@oss" ## special token regarding the changeset for the oss packaging-arm: packaging-arm: "mage package" e2e: @@ -111,3 +117,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^heartbeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/journalbeat/Jenkinsfile.yml b/journalbeat/Jenkinsfile.yml index 17444786286e..4cfe10688d66 100644 --- a/journalbeat/Jenkinsfile.yml +++ b/journalbeat/Jenkinsfile.yml @@ -41,6 +41,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^journalbeat/.*" + - "@oss" ## special token regarding the changeset for the oss packaging-arm: packaging-arm: "mage package" e2e: @@ -48,3 +54,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^journalbeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/metricbeat/Jenkinsfile.yml b/metricbeat/Jenkinsfile.yml index 9142a9a9ca7a..3a66f3e29a75 100644 --- a/metricbeat/Jenkinsfile.yml +++ b/metricbeat/Jenkinsfile.yml @@ -93,6 +93,12 @@ stages: e2e: enabled: false ## e2e is enabled only for x-pack beats stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^metricbeat/.*" + - "@oss" ## special token regarding the changeset for the oss packaging-arm: packaging-arm: "mage package" e2e: @@ -100,3 +106,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^metricbeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/packetbeat/Jenkinsfile.yml b/packetbeat/Jenkinsfile.yml index b49258191fad..5d09046407a8 100644 --- a/packetbeat/Jenkinsfile.yml +++ b/packetbeat/Jenkinsfile.yml @@ -97,6 +97,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^packetbeat/.*" + - "@oss" ## special token regarding the changeset for the oss packaging-arm: packaging-arm: "mage package" e2e: @@ -104,3 +110,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^packetbeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/winlogbeat/Jenkinsfile.yml b/winlogbeat/Jenkinsfile.yml index d90f75009468..092dc8053419 100644 --- a/winlogbeat/Jenkinsfile.yml +++ b/winlogbeat/Jenkinsfile.yml @@ -69,3 +69,9 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^winlogbeat/.*" + - "@oss" ## special token regarding the changeset for the oss diff --git a/x-pack/auditbeat/Jenkinsfile.yml b/x-pack/auditbeat/Jenkinsfile.yml index db9c632bffeb..aef0ec1fbe5e 100644 --- a/x-pack/auditbeat/Jenkinsfile.yml +++ b/x-pack/auditbeat/Jenkinsfile.yml @@ -97,6 +97,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/auditbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -104,3 +110,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/auditbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/dockerlogbeat/Jenkinsfile.yml b/x-pack/dockerlogbeat/Jenkinsfile.yml index 3f71e9df6150..52422328feeb 100644 --- a/x-pack/dockerlogbeat/Jenkinsfile.yml +++ b/x-pack/dockerlogbeat/Jenkinsfile.yml @@ -31,6 +31,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/dockerlogbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -38,3 +44,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/dockerlogbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/elastic-agent/Jenkinsfile.yml b/x-pack/elastic-agent/Jenkinsfile.yml index bda8cbdc6849..a80fdb1297c7 100644 --- a/x-pack/elastic-agent/Jenkinsfile.yml +++ b/x-pack/elastic-agent/Jenkinsfile.yml @@ -97,10 +97,13 @@ stages: e2e: enabled: true testMatrixFile: '.ci/.e2e-tests-for-elastic-agent.yaml' - when: ## Customise when to run this subtask in the packaging stage. - branches: false ## Only on a PR basis for the time being - tags: false ## e2e on branches/tags is already in place with the downstream build. stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/elastic-agent/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -108,3 +111,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/elastic-agent/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/filebeat/Jenkinsfile.yml b/x-pack/filebeat/Jenkinsfile.yml index f062748dd3b3..337e977fc2c6 100644 --- a/x-pack/filebeat/Jenkinsfile.yml +++ b/x-pack/filebeat/Jenkinsfile.yml @@ -115,6 +115,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/filebeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -122,3 +128,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/filebeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/functionbeat/Jenkinsfile.yml b/x-pack/functionbeat/Jenkinsfile.yml index 6c50914a131c..06bdd225a0db 100644 --- a/x-pack/functionbeat/Jenkinsfile.yml +++ b/x-pack/functionbeat/Jenkinsfile.yml @@ -94,3 +94,9 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/functionbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/heartbeat/Jenkinsfile.yml b/x-pack/heartbeat/Jenkinsfile.yml index e886b262c33e..ca184f785f47 100644 --- a/x-pack/heartbeat/Jenkinsfile.yml +++ b/x-pack/heartbeat/Jenkinsfile.yml @@ -88,6 +88,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/heartbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -95,3 +101,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/heartbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/metricbeat/Jenkinsfile.yml b/x-pack/metricbeat/Jenkinsfile.yml index c7aae0d618b6..a9be741ddae5 100644 --- a/x-pack/metricbeat/Jenkinsfile.yml +++ b/x-pack/metricbeat/Jenkinsfile.yml @@ -105,6 +105,12 @@ stages: enabled: false entrypoint: 'metricbeat-test.sh' stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/metricbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -112,3 +118,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/metricbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/osquerybeat/Jenkinsfile.yml b/x-pack/osquerybeat/Jenkinsfile.yml index fcd84745eaa2..fd55f11b63d7 100644 --- a/x-pack/osquerybeat/Jenkinsfile.yml +++ b/x-pack/osquerybeat/Jenkinsfile.yml @@ -78,3 +78,9 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/osquerybeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/packetbeat/Jenkinsfile.yml b/x-pack/packetbeat/Jenkinsfile.yml index 300c716e4e2a..a2550062fb78 100644 --- a/x-pack/packetbeat/Jenkinsfile.yml +++ b/x-pack/packetbeat/Jenkinsfile.yml @@ -98,6 +98,12 @@ stages: e2e: enabled: false stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/packetbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack packaging-arm: packaging-arm: "mage package" e2e: @@ -105,3 +111,9 @@ stages: platforms: ## override default label in this specific stage. - "arm" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/packetbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack diff --git a/x-pack/winlogbeat/Jenkinsfile.yml b/x-pack/winlogbeat/Jenkinsfile.yml index fe37a3f40a94..c3ae1a0a7305 100644 --- a/x-pack/winlogbeat/Jenkinsfile.yml +++ b/x-pack/winlogbeat/Jenkinsfile.yml @@ -71,3 +71,9 @@ stages: platforms: ## override default labels in this specific stage. - "immutable && ubuntu-18" stage: packaging + when: + branches: false ## Only on a PR basis for the time being + tags: false ## packaging on branches/tags is already in place with the downstream build. + changeset: ## when PR contains any of those entries in the changeset + - "^x-pack/winlogbeat/.*" + - "@xpack" ## special token regarding the changeset for the xpack