Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
182 commits
Select commit Hold shift + click to select a range
fa82d1a
[Automation] Update elastic stack version to 8.4.0-40cff009 for testi…
Jun 15, 2022
9e5bb15
[Automation] Update elastic stack version to 8.4.0-5e6770b1 for testi…
Jun 16, 2022
5f66839
Fix regression and use comma separated values (#560)
ph Jun 16, 2022
06ee1dd
Change in Jenkinsfile will trigger k8s run (#568)
ph Jun 16, 2022
86ca6f7
[Automation] Update elastic stack version to 8.4.0-da5a1c6d for testi…
Jun 17, 2022
7b29dbc
Add `@metadata.input_id` and `@metadata.stream_id` when injecting str…
rdner Jun 17, 2022
b728dfe
Add filemod times to contents of diagnostics collect command (#570)
michel-laterman Jun 17, 2022
7db7406
[Automation] Update elastic stack version to 8.4.0-b13123ee for testi…
Jun 20, 2022
d77a91e
Fix Agent upgrade 8.2->8.3 (#578)
aleksmaus Jun 20, 2022
e043f36
Update containerd (#577)
michel-laterman Jun 21, 2022
86ea452
[Automation] Update elastic stack version to 8.4.0-4fe26f2a for testi…
Jun 22, 2022
c876ac4
Set explicit ExitTimeOut for MacOS agent launchd plist (#594)
aleksmaus Jun 23, 2022
89802c6
[Automation] Update elastic stack version to 8.4.0-2e32a640 for testi…
Jun 23, 2022
11ce214
ci: enable build notifications as GitHub issues (#595)
v1v Jun 23, 2022
09d924f
status identifies failing component, fleet gateway may report degrade…
michel-laterman Jun 23, 2022
daa5c5f
[Automation] Update elastic stack version to 8.4.0-722a7d79 for testi…
Jun 24, 2022
90a1f58
ci: enable flaky test detector (#605)
v1v Jun 24, 2022
79bb67e
[Automation] Update elastic stack version to 8.4.0-210dd487 for testi…
Jun 27, 2022
f69d5b1
mergify: remove backport automation for non active branches (#615)
v1v Jun 27, 2022
43ba98d
chore: use elastic-agent profile to run the E2E tests (#610)
mdelapenya Jun 27, 2022
662a07a
[Automation] Update elastic stack version to 8.4.0-a6aa9f3b for testi…
Jun 28, 2022
5c16e08
add macros pointing to new agent's repo and fix old macro calls (#458)
AndersonQ Jun 29, 2022
eb6fa02
Add mount of /etc/machine-id for managed Agent in k8s (#530)
daniel-almeida Jun 29, 2022
5f60fd0
Set hostPID=true for managed agent in k8s (#528)
daniel-almeida Jun 29, 2022
7a4fa6b
[Automation] Update elastic stack version to 8.4.0-86cc80f3 for testi…
Jun 30, 2022
e194fb3
Update elastic-agent-libs version: includes restriction on default Ve…
narph Jun 30, 2022
ed9d75e
redact sensitive information in diagnostics collect command (#566)
AndersonQ Jun 30, 2022
94975cc
Support Cloudbeat regex input type (#638)
ofiriro3 Jun 30, 2022
121a4ad
Disable flaky test download test (#641)
ph Jun 30, 2022
319ea0a
[Automation] Update elastic stack version to 8.4.0-3d206b5d for testi…
Jul 1, 2022
fab95b8
[Automation] Update elastic stack version to 8.4.0-3ad82aa8 for testi…
Jul 4, 2022
acc91fc
jjbb: exclude allowed branches, tags and PRs (#658)
v1v Jul 4, 2022
f8ca007
Update elastic-agent-project-board.yml (#649)
jlind23 Jul 4, 2022
42b1a96
ci: fix labels that clashes with the Orka workers (#659)
v1v Jul 4, 2022
f873f36
[Automation] Update elastic stack version to 8.4.0-03bd6f3f for testi…
Jul 5, 2022
bbd93ff
[Automation] Update elastic stack version to 8.4.0-533f1e30 for testi…
Jul 6, 2022
6c2d91a
Osquerybeat: Fix osquerybeat is not running with logstash output (#674)
aleksmaus Jul 6, 2022
a18cfad
[Automation] Update elastic stack version to 8.4.0-d0a4da44 for testi…
Jul 7, 2022
fe78819
[Automation] Update elastic stack version to 8.4.0-dd98ded4 for testi…
Jul 11, 2022
d1d56a9
[Automation] Update elastic stack version to 8.4.0-164d9a10 for testi…
Jul 12, 2022
bda217d
Add missing license headers (#711)
michel-laterman Jul 12, 2022
be33239
[Automation] Update elastic stack version to 8.4.0-00048b66 for testi…
Jul 13, 2022
28721eb
Allow - in eql variable names (#710)
michel-laterman Jul 13, 2022
0560b46
Fix transpiler to allow : in dynamic variables. (#680)
michel-laterman Jul 13, 2022
4dcc16b
Fix for the filebeat spec file picking up packetbeat inputs (#700)
cmacknz Jul 14, 2022
f4d2b48
[Automation] Update elastic stack version to 8.4.0-3cd57abb for testi…
Jul 15, 2022
a5351f9
[Automation] Update elastic stack version to 8.4.0-a324b98b for testi…
Jul 18, 2022
c6cdfc0
ci: run on MacOS12 (#696)
v1v Jul 18, 2022
21c4812
[Automation] Update elastic stack version to 8.4.0-31315ca3 for testi…
Jul 19, 2022
78019a9
fix typo on package command (#734)
belimawr Jul 19, 2022
e34e0e7
Allow / to be used in variable names (#718)
michel-laterman Jul 19, 2022
8ef98f1
Fix Elastic Agent non-fleet broken upgrade between 8.3.x releases (#701)
aleksmaus Jul 19, 2022
394033d
[Automation] Update elastic stack version to 8.4.0-31269fd2 for testi…
Jul 20, 2022
97e6597
wrap errors and fix some docs typo and convention (#743)
AndersonQ Jul 20, 2022
b0e9623
automate the ironbank docker context generation (#679)
v1v Jul 20, 2022
f26b0eb
Update README.md
pierrehilbert Jul 20, 2022
d84b957
fix flaky (#730)
narph Jul 21, 2022
be3c48e
Add filestream ID on standalone kubernetes manifest (#742)
belimawr Jul 22, 2022
83c4fa2
Alter github action to run on different OSs (#769)
michel-laterman Jul 22, 2022
c05ce63
[Automation] Update elastic stack version to 8.4.0-d058e92f for testi…
Jul 25, 2022
623fe82
elastic-agent manifests: add comments; add cloudnative team as a code…
tetianakravchenko Jul 25, 2022
56f2216
[Elastic-Agent] Added source uri reloading (#686)
michalpristas Jul 26, 2022
3e87782
Update will cleanup unneeded artifacts. (#752)
michel-laterman Jul 26, 2022
87f3798
ci: propagate e2e-testing errors (#695)
v1v Jul 27, 2022
e878103
[Release] add-backport-next (#784)
elasticmachine Jul 27, 2022
317e031
Update main to 8.5.0 (#793)
ph Jul 27, 2022
51e5b0a
[Automation] Update go release version to 1.17.12 (#726)
Jul 27, 2022
8170411
[Automation] Update elastic stack version to 8.4.0-60171339 for testi…
Jul 28, 2022
7a88635
update dependency elastic/go-structform from v0.0.9 to v0.0.10 (#802)
florianl Jul 29, 2022
74ce2ba
Fix unpacking of artifact config (#776)
michalpristas Aug 1, 2022
32afc73
[Automation] Update elastic stack version to 8.5.0-c54c3404 for testi…
Aug 2, 2022
bea990f
[Automation] Update elastic stack version to 8.5.0-7dbc10f8 for testi…
Aug 2, 2022
12c7d15
Fix RPM/DEB clean install (#816)
aleksmaus Aug 2, 2022
ff8de85
fix path for auto generated spec file (#859)
florianl Aug 4, 2022
6d830e8
Reload downloader client on config change (#848)
michalpristas Aug 5, 2022
64cb5a0
Bundle elastic-agent.app for MacOS, needed to be able to enable the …
aleksmaus Aug 8, 2022
940a56c
crossbuild: add fix to set ulimit for debian images (#856)
florianl Aug 9, 2022
dc5b1a2
[Heartbeat] Cleanup docker install / always add playwright deps (#764)
andrewvc Aug 9, 2022
448b218
[Automation] Update elastic stack version to 8.5.0-41aadc32 for testi…
Aug 10, 2022
56787a6
Fix/panic with composable renderer (#823)
ph Aug 10, 2022
4e08c7a
[Automation] Update go release version to 1.18.5 (#832)
Aug 10, 2022
d7f1588
[Automation] Update elastic stack version to 8.5.0-60a4c029 for testi…
Aug 11, 2022
689aee3
Add control-plane toleration to Agent K8S manifests. (#864)
yashtewari Aug 11, 2022
1ebffe9
install mage with go install (#936)
v1v Aug 17, 2022
d4f33d0
Cloudnative ci automation (#837)
gizas Aug 17, 2022
b27a907
Reduce memory footprint by reordering struct elements (#804)
florianl Aug 17, 2022
5316967
[Automation] Update elastic stack version to 8.5.0-6b9f92c0 for testi…
Aug 18, 2022
4eff4f1
[Automation] Update elastic stack version to 8.5.0-0616acda for testi…
Aug 22, 2022
4fffa70
Clarify that this repo is not only docs (#969)
pquentin Aug 22, 2022
c0367b9
Add Filebeat lumberjack input to spec (#959)
andrewkroh Aug 22, 2022
1632dd1
[Automation] Update elastic stack version to 8.5.0-dd6f2bb0 for testi…
Aug 23, 2022
4fdc445
[Automation] Update elastic stack version to 8.5.0-feb644de for testi…
Aug 24, 2022
010e15f
[Automation] Update elastic stack version to 8.5.0-7783a03c for testi…
Aug 25, 2022
1f3f409
[Automation] Update elastic stack version to 8.5.0-17b8a62d for testi…
Aug 26, 2022
91d4854
update ironbank image product name (#1009)
jmlrt Aug 26, 2022
9c0cb45
ci: add extended support for windows (#683)
v1v Aug 26, 2022
9298e01
[Automation] Update elastic stack version to 8.5.0-9aed3b11 for testi…
Aug 29, 2022
3e89bfc
Cloudnative ci utomation (#1035)
gizas Aug 30, 2022
64f0c3c
[Automation] Update elastic stack version to 8.5.0-fedc3e60 for testi…
Aug 31, 2022
f3852cf
Testing PR creation for 706 (#1049)
gizas Aug 31, 2022
2522be4
Fix lookup issues with inputs.d fragment yml (#840)
ph Aug 31, 2022
54f3697
[Automation] Update elastic stack version to 8.5.0-b5001a6d for testi…
Sep 1, 2022
a0957c7
[Automation] Update elastic stack version to 8.5.0-1bd77fc1 for testi…
Sep 5, 2022
25411d2
[Automation] Update elastic stack version to 8.5.0-167dfc80 for testi…
Sep 6, 2022
ffc6c00
Adding support for v1.25.0 k8s (#1044)
gizas Sep 6, 2022
5ca0ae1
[Automation] Update elastic stack version to 8.5.0-6b7dda2d for testi…
Sep 7, 2022
7a8aeb4
[Automation] Update elastic stack version to 8.5.0-4140365c for testi…
Sep 8, 2022
3951c33
Remove experimental warning log in upgrade command (#1106)
joshdover Sep 8, 2022
802f27e
Update go.mod to Go 1.18, update notice. (#1120)
cmacknz Sep 8, 2022
6e2e06c
Remove the fleet reporter (#1130)
michel-laterman Sep 9, 2022
458c8ae
[Automation] Update elastic stack version to 8.5.0-589a4a10 for testi…
Sep 12, 2022
d811ef3
Avoid reporting `Unhealthy` on fleet connectivity issues (#1152)
michalpristas Sep 12, 2022
c8c313d
ci: enable MacOS M1 stages (#1123)
v1v Sep 12, 2022
8a00e80
[Automation] Update go release version to 1.18.6 (#1143)
Sep 12, 2022
2730049
[Automation] Update elastic stack version to 8.5.0-37418cf3 for testi…
Sep 13, 2022
9b17473
Remove mage notice in favour of make notice (#1108)
belimawr Sep 13, 2022
6fb3a93
ci: run e2e-testing at the end (#1169)
v1v Sep 13, 2022
3fb21ea
ci: move macos to github actions (#1175)
v1v Sep 13, 2022
eb3a698
[Automation] Update elastic stack version to 8.5.0-fcf3d4c2 for testi…
Sep 14, 2022
59f9ac4
Add support for hints' based autodiscovery in kubernetes provider (#698)
ChrsMark Sep 14, 2022
558380b
ci: increase timeout (#1190)
v1v Sep 14, 2022
332d08d
Fixing condition for PR creation (#1188)
gizas Sep 14, 2022
8b711f3
Fix leftover log level (#1194)
ChrsMark Sep 14, 2022
ae2c942
[automation] Publish kubernetes templates for elastic-agent (#1192)
elasticmachine Sep 14, 2022
a7c48ef
ci: force GO_VERSION (#1204)
v1v Sep 14, 2022
270295f
Fix whitespaces in vault_darwin.c (#1206)
aleksmaus Sep 14, 2022
5a0ba4d
Update kubernetes templates for elastic-agent [templates.d] (#1231)
elasticmachine Sep 19, 2022
a0620af
Use at least warning level for all status logs (#1218)
joshdover Sep 19, 2022
ec2816d
Update k8s manifests to leverage hints (#1202)
ChrsMark Sep 19, 2022
a0a3ed1
Add Go 1.18 upgrade to breaking changes section. (#1216)
cmacknz Sep 19, 2022
6b5e6d0
[Release] add-backport-next (#1254)
elasticmachine Sep 21, 2022
5989089
Bump version to 8.6.0. (#1259)
cmacknz Sep 21, 2022
7d21718
[Automation] Update elastic stack version to 8.5.0-7dc445a0 for testi…
Sep 21, 2022
815382d
Fix: Endpoint collision between monitoring and regular beats (#1034)
michalpristas Sep 22, 2022
28fab94
internal/pkg/agent/cmd: don't format error message with nil errors (#…
efd6 Sep 23, 2022
7af8092
[Automation] Update elastic stack version to 8.6.0-21651da3 for testi…
Sep 26, 2022
2b6cfdc
Fixed: source uri reload for download/verify components (#1252)
michalpristas Sep 26, 2022
717708a
Expand status reporter/controller interfaces to allow local reporters…
michel-laterman Sep 26, 2022
5225e54
Improve logging for agent upgrades. (#1287)
cmacknz Sep 26, 2022
6a0fd1b
[Automation] Update elastic stack version to 8.6.0-326f84b0 for testi…
Sep 27, 2022
faf98e7
[Automation] Update elastic stack version to 8.6.0-df00693f for testi…
Sep 28, 2022
e614321
Add success log message after previous checkin failures (#1327)
joshdover Sep 28, 2022
177b5fb
Fix status reporter initialization (#1341)
AndersonQ Sep 28, 2022
c35935d
[Automation] Update elastic stack version to 8.6.0-a2f4f140 for testi…
Sep 29, 2022
4d7fae9
Added status message to CheckinRequest (#1369)
juliaElastic Sep 29, 2022
e184051
Fix failures when using npipe monitoring endpoints (#1371)
michalpristas Sep 29, 2022
c6a22d4
[Automation] Update elastic stack version to 8.6.0-158a13db for testi…
Sep 30, 2022
90c2c00
Mount /etc directory in Kubernetes DaemonSet manifests. (#1382)
yashtewari Oct 3, 2022
6d40875
[Automation] Update elastic stack version to 8.6.0-aea1c645 for testi…
Oct 4, 2022
7155492
[Automation] Update elastic stack version to 8.6.0-0fca2953 for testi…
Oct 5, 2022
f4b8e2e
ci: 7.17 is not available for the daily run (#1417)
v1v Oct 5, 2022
166e7f6
[Automation] Update elastic stack version to 8.6.0-e4c15f15 for testi…
Oct 6, 2022
bd06f46
[backport main] Fix: Agent failed to upgrade from 8.4.2 to 8.5.0 BC1 …
aleksmaus Oct 6, 2022
2223138
Fix docker provider add_fields processors (#1420)
belimawr Oct 6, 2022
d8c9939
[Automation] Update elastic stack version to 8.6.0-d939cfde for testi…
Oct 7, 2022
b0a98e2
[Automation] Update elastic stack version to 8.6.0-7c9f25a9 for testi…
Oct 10, 2022
a3ea750
Enable integration only when datastreams are not defined (#1456)
ChrsMark Oct 10, 2022
f772a3d
Add not dedoted k8s pod labels in autodiscover provider to be used fo…
MichaelKatsoulis Oct 10, 2022
0efbca6
[Automation] Update elastic stack version to 8.6.0-c49fac70 for testi…
Oct 11, 2022
7f813fa
Add storageclass permissions in agent clusterrole (#1470)
MichaelKatsoulis Oct 11, 2022
6223273
Remote QA-labels automation (#1455)
jlind23 Oct 11, 2022
6c325d0
[Automation] Update go release version to 1.18.7 (#1444)
Oct 11, 2022
070af5f
[Automation] Update elastic stack version to 8.6.0-5a8d757d for testi…
Oct 12, 2022
cd6ad3d
Improve logging around agent checkins. (#1477)
cmacknz Oct 12, 2022
12c5553
[Automation] Update elastic stack version to 8.6.0-40086bc7 for testi…
Oct 13, 2022
d5cfe6f
Fixing makefile check (#1490)
gizas Oct 13, 2022
259682d
action: validate changelog fragment (#1488)
v1v Oct 13, 2022
5505f58
Allign managed with standalone role (#1500)
gizas Oct 13, 2022
8904833
Fix k8s template link versioning (#1504)
ChrsMark Oct 13, 2022
7f5450b
Allighningmanifests (#1507)
gizas Oct 13, 2022
35f12d5
[Automation] Update elastic stack version to 8.6.0-233dc5d4 for testi…
Oct 14, 2022
6eadeef
Convert CHANGELOG.next to fragments (#1244)
endorama Oct 14, 2022
9c6a43b
[Automation] Update elastic stack version to 8.6.0-54a302f0 for testi…
Oct 17, 2022
e64ea9a
Update the linter configuration. (#1478)
cmacknz Oct 17, 2022
d2c780b
Elastic agent counterpart of https://github.com/elastic/beats/pull/33…
andrewvc Oct 17, 2022
edc1e85
[Automation] Update elastic stack version to 8.6.0-cae815eb for testi…
Oct 18, 2022
33a5f7e
Fix admin permission check on localized windows (#1552)
michalpristas Oct 18, 2022
0215b42
Merge branch 'main' into merge-main-oct18
blakerouse Oct 18, 2022
962df8b
Fixes from merge of main.
blakerouse Oct 18, 2022
d555eb4
Merge branch 'feature-arch-v2' into merge-main-oct18
blakerouse Oct 19, 2022
2f934f1
Update heartbeat specification to only support elasticsearch.
blakerouse Oct 20, 2022
8b4f171
Fix bad merge in dockerfile.
blakerouse Oct 20, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
183 changes: 178 additions & 5 deletions .ci/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ pipeline {
DEVELOPER_MODE=true
}
options {
timeout(time: 2, unit: 'HOURS')
timeout(time: 3, unit: 'HOURS')
buildDiscarder(logRotator(numToKeepStr: '20', artifactNumToKeepStr: '20', daysToKeepStr: '30'))
timestamps()
ansiColor('xterm')
Expand All @@ -39,6 +39,14 @@ pipeline {
// disabled by default, but required for merge:
// opt-in with 'ci:end-to-end' tag on PR
booleanParam(name: 'end_to_end_tests_ci', defaultValue: false, description: 'Enable End-to-End tests')

// disabled by default, but required for merge:
// opt-in with 'ci:extended-windows' tag on PR
booleanParam(name: 'extended_windows_ci', defaultValue: false, description: 'Enable Extended Windows tests')

// disabled by default, but required for merge:
// opt-in with 'ci:extended-m1' tag on PR
booleanParam(name: 'extended_m1_ci', defaultValue: false, description: 'Enable M1 tests')
}
stages {
stage('Checkout') {
Expand All @@ -51,6 +59,10 @@ pipeline {
setEnvVar('ONLY_DOCS', isGitRegionMatch(patterns: [ '.*\\.(asciidoc|md)' ], shouldMatchAll: true).toString())
setEnvVar('PACKAGING_CHANGES', isGitRegionMatch(patterns: [ '(^dev-tools/packaging/.*|.ci/Jenkinsfile)' ], shouldMatchAll: false).toString())
setEnvVar('K8S_CHANGES', isGitRegionMatch(patterns: [ '(^deploy/kubernetes/.*|^version/docs/version.asciidoc|.ci/Jenkinsfile)' ], shouldMatchAll: false).toString())
setEnvVar('EXT_WINDOWS_CHANGES', isGitRegionMatch(patterns: [ '.ci/Jenkinsfile' ], shouldMatchAll: false).toString())
setEnvVar('EXT_M1_CHANGES', isGitRegionMatch(patterns: [ '.ci/Jenkinsfile' ], shouldMatchAll: false).toString())
// set the GO_VERSION env variable with the go version to be used in withMageEnv
setEnvVar('GO_VERSION', readFile(file: '.go-version')?.trim())
}
}
}
Expand Down Expand Up @@ -79,7 +91,8 @@ pipeline {
axes {
axis {
name 'PLATFORM'
values 'ubuntu-20.04 && immutable', 'aws && aarch64', 'windows-2016 && windows-immutable', 'windows-2022 && windows-immutable', 'macos12 && x86_64'
// Orka workers are not healthy (memory and connectivity issues)
values 'ubuntu-20.04 && immutable', 'aws && aarch64', 'windows-2016 && windows-immutable', 'windows-2022 && windows-immutable' //, 'macos12 && x86_64'
}
}
stages {
Expand Down Expand Up @@ -147,7 +160,7 @@ pipeline {
}
}
steps {
runK8s(k8sVersion: 'v1.23.0', kindVersion: 'v0.11.1', context: "K8s-${PLATFORM}")
runK8s(k8sVersion: 'v1.25.0-beta.0', kindVersion: 'v0.14.0', context: "K8s-${PLATFORM}")
}
}
stage('Package') {
Expand Down Expand Up @@ -219,7 +232,7 @@ pipeline {
axes {
axis {
name 'K8S_VERSION'
values "v1.24.0", "v1.23.6", "v1.22.9", "v1.21.12"
values "v1.25.0","v1.24.3", "v1.23.6", "v1.22.9"
}
}
stages {
Expand All @@ -238,6 +251,153 @@ pipeline {
}
}
}
stage('Sync K8s') { //This stage opens a PR to kibana Repository in order to sync k8s manifests
when {
// Only on main branch
// Enable if k8s related changes.
allOf {
branch 'main' // Only runs for branch main
expression { return env.K8S_CHANGES == "true" } // If k8s changes
}
}
failFast false
agent {label 'ubuntu-20.04 && immutable'}
options { skipDefaultCheckout() }
stages {
stage('OpenKibanaPR') {
steps {
withGhEnv(version: '2.4.0') {
deleteDir()
unstashV2(name: 'source', bucket: "${JOB_GCS_BUCKET}", credentialsId: "${JOB_GCS_CREDENTIALS}")
dir("${BASE_DIR}/deploy/kubernetes"){
sh(label: '[File Creation] Create-Needed-Manifest', script: """
WITHOUTCONFIG=true make generate-k8s
./creator_k8s_manifest.sh . """)
sh(label: '[Clone] Kibana-Repository', script: """
make ci-clone-kibana-repository
cp Makefile ./kibana
cd kibana
make ci-create-kubernetes-templates-pull-request """)
}
}
}
post {
always {
junit(allowEmptyResults: true, keepLongStdio: true, testResults: "${BASE_DIR}/build/TEST-*.xml")
}
}
}
}
}
stage('extended windows') {
when {
// Always when running builds on branches/tags
// Enable if extended windows support related changes.
beforeAgent true
anyOf {
not { changeRequest() }
expression { return isExtendedWindowsEnabled() && env.ONLY_DOCS == "false"}
}
}
failFast false
matrix {
agent {label "${PLATFORM} && windows-immutable"}
options { skipDefaultCheckout() }
axes {
axis {
name 'PLATFORM'
values 'windows-8', 'windows-10', 'windows-11'
}
}
stages {
stage('build'){
options { skipDefaultCheckout() }
steps {
withGithubNotify(context: "Build-${PLATFORM}") {
deleteDir()
unstashV2(name: 'source', bucket: "${JOB_GCS_BUCKET}", credentialsId: "${JOB_GCS_CREDENTIALS}")
withMageEnv(){
dir("${BASE_DIR}"){
cmd(label: 'Go build', script: 'mage build')
}
}
}
}
}
stage('Test') {
options { skipDefaultCheckout() }
steps {
withGithubNotify(context: "Test-${PLATFORM}") {
withMageEnv(){
dir("${BASE_DIR}"){
withEnv(["TEST_COVERAGE=${isCodeCoverageEnabled()}"]) {
cmd(label: 'Go unitTest', script: 'mage unitTest')
}
}
}
}
}
post {
always {
junit(allowEmptyResults: true, keepLongStdio: true, testResults: "${BASE_DIR}/build/TEST-*.xml")
whenTrue(isCodeCoverageEnabled()) {
coverageReport(baseDir: "**/build", reportFiles: 'TEST-go-unit.html', coverageFiles: 'TEST-go-unit-cov.xml')
}
}
}
}
}
}
}
stage('m1') {
agent { label 'orka && darwin && aarch64' }
options { skipDefaultCheckout() }
when {
// Always when running builds on branches/tags
// Enable if extended M1 support related changes.
beforeAgent true
anyOf {
not { changeRequest() }
expression { return isExtendedM1Enabled() && env.ONLY_DOCS == "false"}
}
}
stages {
stage('build'){
steps {
withGithubNotify(context: "Build-darwin-aarch64") {
deleteDir()
unstashV2(name: 'source', bucket: "${JOB_GCS_BUCKET}", credentialsId: "${JOB_GCS_CREDENTIALS}")
withMageEnv(){
dir("${BASE_DIR}"){
cmd(label: 'Go build', script: 'mage build')
}
}
}
}
}
stage('Test') {
steps {
withGithubNotify(context: "Test-darwin-aarch64") {
withMageEnv(){
dir("${BASE_DIR}"){
withEnv(["TEST_COVERAGE=${isCodeCoverageEnabled()}"]) {
cmd(label: 'Go unitTest', script: 'mage unitTest')
}
}
}
}
}
post {
always {
junit(allowEmptyResults: true, keepLongStdio: true, testResults: "${BASE_DIR}/build/TEST-*.xml")
whenTrue(isCodeCoverageEnabled()) {
coverageReport(baseDir: "**/build", reportFiles: 'TEST-go-unit.html', coverageFiles: 'TEST-go-unit-cov.xml')
}
}
}
}
}
}
stage('e2e tests') {
when {
// Always when running builds on branches/tags
Expand All @@ -250,7 +410,6 @@ pipeline {
}
}
steps {
// TODO: what's the testMatrixFile to be used if any
runE2E(testMatrixFile: '.ci/.e2e-tests-for-elastic-agent.yaml',
beatVersion: "${env.BEAT_VERSION}-SNAPSHOT",
elasticAgentVersion: "${env.BEAT_VERSION}-SNAPSHOT",
Expand Down Expand Up @@ -374,3 +533,17 @@ def isE2eEnabled() {
def isPackageEnabled() {
return env.PACKAGING_CHANGES == "true" || env.GITHUB_COMMENT?.contains('package') || matchesPrLabel(label: 'ci:package')
}

/**
* Wrapper to know if the build should enable the windows extended support
*/
def isExtendedWindowsEnabled() {
return env.EXT_WINDOWS_CHANGES == "true" || params.extended_windows_ci || env.GITHUB_COMMENT?.contains('extended windows') || matchesPrLabel(label: 'ci:extended-windows')
}

/**
* Wrapper to know if the build should enable the M1 extended support
*/
def isExtendedM1Enabled() {
return env.EXT_M1_CHANGES == "true" || params.extended_m1_ci || env.GITHUB_COMMENT?.contains('extended m1') || matchesPrLabel(label: 'ci:extended-m1')
}
2 changes: 1 addition & 1 deletion .ci/schedule-daily.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ pipeline {
stages {
stage('Nighly beats builds') {
steps {
runBuilds(quietPeriodFactor: 2000, branches: ['main', '8.<minor>', '8.<next-patch>', '7.<minor>'])
runBuilds(quietPeriodFactor: 2000, branches: ['main', '8.<minor>', '8.<next-patch>'])
}
}
}
Expand Down
17 changes: 17 additions & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Changelog
on: [pull_request]

jobs:
fragments:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
- name: check pr-has-fragment
run: |
GOBIN=$PWD/bin go install github.com/elastic/elastic-agent-changelog-tool@latest
./bin/elastic-agent-changelog-tool pr-has-fragment --repo ${{ github.event.repository.name }} ${{github.event.number}}
8 changes: 4 additions & 4 deletions .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,22 +18,22 @@ jobs:
name: lint
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

# Uses Go version from the repository.
- name: Read .go-version file
id: goversion
run: echo "::set-output name=version::$(cat .go-version)"

- uses: actions/setup-go@v2
- uses: actions/setup-go@v3
with:
go-version: "${{ steps.goversion.outputs.version }}"

- name: golangci-lint
uses: golangci/golangci-lint-action@v2
uses: golangci/golangci-lint-action@v3
with:
# Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version
version: v1.45.2
version: v1.47.2

# Give the job more time to execute.
# Regarding `--whole-files`, the linter is supposed to support linting of changed a patch only but,
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/macos.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: macos

on:
pull_request:
push:
branches:
- main
- 8.*

jobs:
macos:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- name: Fetch Go version from .go-version
run: echo "GO_VERSION=$(cat .go-version)" >> $GITHUB_ENV
- uses: actions/setup-go@v3
with:
go-version: ${{ env.GO_VERSION }}
- name: Install dependencies
run: go install github.com/magefile/mage
- name: Run build
run: mage build
- name: Run test
run: mage unitTest
Loading