From 5b88675dec75d0c70ef4a5ce7245a0940bc76c32 Mon Sep 17 00:00:00 2001 From: Victor Martinez Date: Fri, 16 Oct 2020 09:50:37 +0100 Subject: [PATCH] [CI] Support Windows-2012 in pipeline 2.0 (#21338) (#21806) --- Jenkinsfile | 3 ++- auditbeat/Jenkinsfile.yml | 11 +++++++++++ heartbeat/Jenkinsfile.yml | 12 ++++++++++++ metricbeat/Jenkinsfile.yml | 11 +++++++++++ packetbeat/Jenkinsfile.yml | 11 +++++++++++ winlogbeat/Jenkinsfile.yml | 11 +++++++++++ x-pack/auditbeat/Jenkinsfile.yml | 11 +++++++++++ x-pack/elastic-agent/Jenkinsfile.yml | 11 +++++++++++ x-pack/filebeat/Jenkinsfile.yml | 11 +++++++++++ x-pack/functionbeat/Jenkinsfile.yml | 11 +++++++++++ x-pack/metricbeat/Jenkinsfile.yml | 11 +++++++++++ x-pack/packetbeat/Jenkinsfile.yml | 11 +++++++++++ x-pack/winlogbeat/Jenkinsfile.yml | 11 +++++++++++ 13 files changed, 135 insertions(+), 1 deletion(-) diff --git a/Jenkinsfile b/Jenkinsfile index 1f8310682c3..fd6bb5d414e 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -242,9 +242,10 @@ def withBeatsEnv(Map args = [:], Closure body) { artifacts = '**/build/TEST*.out' } else { def chocoPath = 'C:\\ProgramData\\chocolatey\\bin' + def mingw64Path = 'C:\\tools\\mingw64\\bin' def chocoPython3Path = 'C:\\Python38;C:\\Python38\\Scripts' goRoot = "${env.USERPROFILE}\\.gvm\\versions\\go${GO_VERSION}.windows.amd64" - path = "${env.WORKSPACE}\\bin;${goRoot}\\bin;${chocoPath};${chocoPython3Path};${env.PATH}" + path = "${env.WORKSPACE}\\bin;${goRoot}\\bin;${chocoPath};${chocoPython3Path};${env.PATH};${mingw64Path}" magefile = "${env.WORKSPACE}\\.magefile" testResults = "**\\build\\TEST*.xml" artifacts = "**\\build\\TEST*.out" diff --git a/auditbeat/Jenkinsfile.yml b/auditbeat/Jenkinsfile.yml index 7eed06a497c..b3f20af2d37 100644 --- a/auditbeat/Jenkinsfile.yml +++ b/auditbeat/Jenkinsfile.yml @@ -58,3 +58,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test auditbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/heartbeat/Jenkinsfile.yml b/heartbeat/Jenkinsfile.yml index c054be0cd53..1d41dbe581e 100644 --- a/heartbeat/Jenkinsfile.yml +++ b/heartbeat/Jenkinsfile.yml @@ -56,3 +56,15 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test heartbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags + diff --git a/metricbeat/Jenkinsfile.yml b/metricbeat/Jenkinsfile.yml index 9860919d006..bdd45090837 100644 --- a/metricbeat/Jenkinsfile.yml +++ b/metricbeat/Jenkinsfile.yml @@ -51,3 +51,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test metricbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/packetbeat/Jenkinsfile.yml b/packetbeat/Jenkinsfile.yml index 7ecdbbfca8f..adf6471b82a 100644 --- a/packetbeat/Jenkinsfile.yml +++ b/packetbeat/Jenkinsfile.yml @@ -56,3 +56,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test packetbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/winlogbeat/Jenkinsfile.yml b/winlogbeat/Jenkinsfile.yml index 82ce7912d3b..94b36b0e647 100644 --- a/winlogbeat/Jenkinsfile.yml +++ b/winlogbeat/Jenkinsfile.yml @@ -30,3 +30,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test winlogbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/auditbeat/Jenkinsfile.yml b/x-pack/auditbeat/Jenkinsfile.yml index 5850d9947b4..1294c4681b4 100644 --- a/x-pack/auditbeat/Jenkinsfile.yml +++ b/x-pack/auditbeat/Jenkinsfile.yml @@ -57,3 +57,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test auditbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/elastic-agent/Jenkinsfile.yml b/x-pack/elastic-agent/Jenkinsfile.yml index 3a4c54c414d..bf1bfed3ddd 100644 --- a/x-pack/elastic-agent/Jenkinsfile.yml +++ b/x-pack/elastic-agent/Jenkinsfile.yml @@ -56,3 +56,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test x-pack/elastic-agent for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/filebeat/Jenkinsfile.yml b/x-pack/filebeat/Jenkinsfile.yml index d8cef3dd206..5bd2bcd40cf 100644 --- a/x-pack/filebeat/Jenkinsfile.yml +++ b/x-pack/filebeat/Jenkinsfile.yml @@ -57,3 +57,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test x-pack/filebeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/functionbeat/Jenkinsfile.yml b/x-pack/functionbeat/Jenkinsfile.yml index 098746ff606..ecb2bd14e0e 100644 --- a/x-pack/functionbeat/Jenkinsfile.yml +++ b/x-pack/functionbeat/Jenkinsfile.yml @@ -54,3 +54,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test x-pack/functionbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/metricbeat/Jenkinsfile.yml b/x-pack/metricbeat/Jenkinsfile.yml index d02dc5e16aa..60a593c488d 100644 --- a/x-pack/metricbeat/Jenkinsfile.yml +++ b/x-pack/metricbeat/Jenkinsfile.yml @@ -46,3 +46,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test x-pack/metricbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/packetbeat/Jenkinsfile.yml b/x-pack/packetbeat/Jenkinsfile.yml index fd30546f70a..e3fa9ad0324 100644 --- a/x-pack/packetbeat/Jenkinsfile.yml +++ b/x-pack/packetbeat/Jenkinsfile.yml @@ -29,3 +29,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test x-pack/winlogbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags diff --git a/x-pack/winlogbeat/Jenkinsfile.yml b/x-pack/winlogbeat/Jenkinsfile.yml index 788d4a35369..371f0aa6f48 100644 --- a/x-pack/winlogbeat/Jenkinsfile.yml +++ b/x-pack/winlogbeat/Jenkinsfile.yml @@ -29,3 +29,14 @@ stages: - "windows-2016" branches: true ## for all the branches tags: true ## for all the tags + windows-2012: + mage: "mage build unitTest" + platforms: ## override default labels in this specific stage. + - "windows-2012-r2" + when: ## Override the top-level when. + comments: + - "/test x-pack/winlogbeat for windows-2012" + labels: + - "windows-2012" + branches: true ## for all the branches + tags: true ## for all the tags