Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure correct bom version when jenkins version updated #150

Merged
merged 1 commit into from
Nov 14, 2023
Merged
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
26 changes: 26 additions & 0 deletions updatecli/updatecli.d/update-jenkins-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,21 @@ sources:
github:
token: '{{ requiredEnv .github.token }}'
username: '{{ .github.username }}'
bom:
name: Get latest BOM line
kind: jenkins
spec:
release: stable
transformers:
- trimsuffix: ".(.*)$"
- trimsuffix: ".2"
- trimsuffix: ".3"
- trimsuffix: ".4"
- addprefix: "bom-"
- addsuffix: ".x"
github:
token: '{{ requiredEnv .github.token }}'
username: '{{ .github.username }}'
targets:
jenkins:
name: Update Jenkins Version
Expand All @@ -28,13 +43,24 @@ targets:
file: pom.xml
matchpattern: '<jenkins.version>(.*)</jenkins.version>'
replacepattern: '<jenkins.version>{{ source `jenkins` }}</jenkins.version>'
bom:
name: Ensure Jenkins BOM version
sourceid: jenkins
scmid: github
kind: file
spec:
file: pom.xml
matchpattern: '<artifactId>bom-(.*).x</artifactId>'
replacepattern: '<artifactId>{{ source `bom` }}</artifactId>'
actions:
jenkins:
title: Bump Jenkins version {{ source "jenkins" }}
disablepipelineurl: true
kind: github/pullrequest
scmid: github
targets:
- jenkins
- bom
spec:
labels:
- dependencies
Expand Down