Skip to content
This repository was archived by the owner on Sep 17, 2024. It is now read-only.

jjbb: daily job with branch aliases #2159

Merged
merged 6 commits into from
Feb 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions .backportrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
"multipleCommits": true,
"prTitle": "{commitMessages} backport for {targetBranch}",
"targetBranchChoices": [
{ "name": "8.1", "checked": true },
{ "name": "8.0", "checked": true },
{ "name": "7.17", "checked": true },
{ "name": "7.16", "checked": true }
{ "name": "7.17", "checked": true }
],
"targetPRLabels": ["backport"],
"upstream": "elastic/e2e-testing"
Expand Down
3 changes: 0 additions & 3 deletions .ci/e2eTestingFleetDaily.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,6 @@ pipeline {
rateLimitBuilds(throttle: [count: 60, durationName: 'hour', userBoost: true])
quietPeriod(10)
}
triggers {
cron('H H(4-5) * * 1-5')
}
stages {
stage('Run Tests') {
steps {
Expand Down
3 changes: 0 additions & 3 deletions .ci/e2eTestingHelmDaily.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,6 @@ pipeline {
rateLimitBuilds(throttle: [count: 60, durationName: 'hour', userBoost: true])
quietPeriod(10)
}
triggers {
cron('H H(4-5) * * 1-5')
}
stages {
stage('Run Tests') {
steps {
Expand Down
3 changes: 0 additions & 3 deletions .ci/e2eTestingK8SAutodiscoveryDaily.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,6 @@ pipeline {
rateLimitBuilds(throttle: [count: 60, durationName: 'hour', userBoost: true])
quietPeriod(10)
}
triggers {
cron('H H(4-5) * * 1-5')
}
stages {
stage('Run Tests') {
steps {
Expand Down
2 changes: 1 addition & 1 deletion .ci/jobs/e2e-testing-fleet-daily-mbp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
scm:
- github:
branch-discovery: no-pr
head-filter-regex: '(main|8\.1|8\.0|7\.17)'
head-filter-regex: '(main|8\.\d|7\.17|7\.16)'
discover-pr-forks-strategy: merge-current
discover-pr-forks-trust: permission
discover-pr-origin: merge-current
Expand Down
2 changes: 1 addition & 1 deletion .ci/jobs/e2e-testing-helm-daily-mbp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
scm:
- github:
branch-discovery: no-pr
head-filter-regex: '(main|8\.1|8\.0|7\.17)'
head-filter-regex: '(main|8\.\d|7\.17|7\.16)'
discover-pr-forks-strategy: merge-current
discover-pr-forks-trust: permission
discover-pr-origin: merge-current
Expand Down
2 changes: 1 addition & 1 deletion .ci/jobs/e2e-testing-k8s-autodiscovery-daily-mbp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
scm:
- github:
branch-discovery: no-pr
head-filter-regex: '(main|8\.1|8\.0|7\.17)'
head-filter-regex: '(main|8\.\d|7\.17|7\.16)'
discover-pr-forks-strategy: merge-current
discover-pr-forks-trust: permission
discover-pr-origin: merge-current
Expand Down
26 changes: 26 additions & 0 deletions .ci/jobs/e2e-testing-schedule-daily.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
- job:
name: e2e-tests/e2e-testing-schedule-daily
display-name: Jobs scheduled daily (weekdays)
description: Jobs scheduled daily (weekdays)
view: E2E
project-type: pipeline
parameters:
- string:
name: branch_specifier
default: main
description: the Git branch specifier to build
pipeline-scm:
script-path: .ci/schedule-daily.groovy
scm:
- git:
url: [email protected]:elastic/e2e-testing.git
refspec: +refs/heads/*:refs/remotes/origin/*
wipe-workspace: 'True'
name: origin
shallow-clone: true
credentials-id: f6c7695a-671e-4f4f-a331-acdce44ff9ba
branches:
- $branch_specifier
triggers:
- timed: 'H H(2-3) * * 1-5'
45 changes: 45 additions & 0 deletions .ci/schedule-daily.groovy
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
@Library('apm@current') _

pipeline {
agent none
environment {
NOTIFY_TO = credentials('notify-to')
PIPELINE_LOG_LEVEL = 'INFO'
}
options {
timeout(time: 1, unit: 'HOURS')
buildDiscarder(logRotator(numToKeepStr: '20', artifactNumToKeepStr: '20'))
timestamps()
ansiColor('xterm')
disableResume()
durabilityHint('PERFORMANCE_OPTIMIZED')
}
triggers {
cron('H H(4-5) * * 1-5')
}
stages {
stage('Nighly e2e builds') {
steps {
runBuilds(quietPeriodFactor: 100, branches: ['main', '8.<minor>', '8.<next-patch>', '7.<minor>'])
}
}
}
post {
cleanup {
notifyBuildResult(prComment: false)
}
}
}

def runBuilds(Map args = [:]) {
def branches = getBranchesFromAliases(aliases: args.branches)

def quietPeriod = 0
branches.each { branch ->
build(quietPeriod: quietPeriod, job: "e2e-tests/e2e-testing-fleet-daily-mbp/${branch}", wait: false, propagate: false)
build(quietPeriod: quietPeriod, job: "e2e-tests/e2e-testing-helm-daily-mbp/${branch}", wait: false, propagate: false)
build(quietPeriod: quietPeriod, job: "e2e-tests/e2e-testing-k8s-autodiscovery-daily-mbp/${branch}", wait: false, propagate: false)
// Increate the quiet period for the next iteration
quietPeriod += args.quietPeriodFactor
}
}
18 changes: 9 additions & 9 deletions .mergify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,41 +18,41 @@ pull_request_rules:
git merge upstream/{{base}}
git push upstream {{head}}
```
- name: backport patches to 8.0 branch
- name: backport patches to 8.1 branch
conditions:
- merged
- base=main
- label=backport-v8.0.0
- label=backport-v8.1.0
actions:
backport:
assignees:
- "{{ author }}"
branches:
- "8.0"
- "8.1"
title: "[{{ destination_branch }}](backport #{{ number }}) {{ title }}"
- name: backport patches to 7.17 branch
- name: backport patches to 8.0 branch
conditions:
- merged
- base=main
- label=backport-v7.17.0
- label=backport-v8.0.0
actions:
backport:
assignees:
- "{{ author }}"
branches:
- "7.17"
- "8.0"
title: "[{{ destination_branch }}](backport #{{ number }}) {{ title }}"
- name: backport patches to 7.16 branch
- name: backport patches to 7.17 branch
conditions:
- merged
- base=main
- label=backport-v7.16.0
- label=backport-v7.17.0
actions:
backport:
assignees:
- "{{ author }}"
branches:
- "7.16"
- "7.17"
title: "[{{ destination_branch }}](backport #{{ number }}) {{ title }}"
- name: delete head branch after merge
conditions:
Expand Down