Skip to content

Commit a0ab3fa

Browse files
authored
chore(updatecli): keep default JENKINS_VERSION and WAR_SHA up to date (#2171)
* chore(updatecli): add a manifest to keep default `JENKINS_VERSION` up to date * remove unused currentVersion source * add missing `name` to `updateGoldenFiles` * align naming and order with #2172 * don't update LTS expected tags (follow-up of #2184) * retrieve latest Jenkins Core version from updates.jenkins.io
1 parent f8cf8fa commit a0ab3fa

File tree

1 file changed

+82
-0
lines changed

1 file changed

+82
-0
lines changed
Lines changed: 82 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,82 @@
1+
---
2+
name: Bump default `JENKINS_VERSION` version
3+
4+
scms:
5+
default:
6+
kind: github
7+
spec:
8+
user: "{{ .github.user }}"
9+
email: "{{ .github.email }}"
10+
owner: "{{ .github.owner }}"
11+
repository: "{{ .github.repository }}"
12+
token: "{{ requiredEnv .github.token }}"
13+
username: "{{ .github.username }}"
14+
branch: "{{ .github.branch }}"
15+
16+
sources:
17+
latestVersion:
18+
kind: file
19+
name: Get latest Jenkins Core release version
20+
spec:
21+
file: https://updates.jenkins.io/latestCore.txt
22+
latestWarSha:
23+
kind: shell
24+
name: Get latest Jenkins Core sha256 checksum
25+
spec:
26+
command: curl --disable --fail --silent --show-error --location "https://repo.jenkins-ci.org/releases/org/jenkins-ci/main/jenkins-war/{{ source "latestVersion" }}/jenkins-war-{{ source "latestVersion" }}.war.sha256"
27+
28+
conditions:
29+
isDockerImagePublished:
30+
name: Check if the docker image has been published
31+
kind: dockerimage
32+
sourceid: latestVersion
33+
spec:
34+
image: jenkins/jenkins
35+
36+
targets:
37+
updateJenkinsVersionInDockerBake:
38+
name: Update default value of JENKINS_VERSION in docker-bake.hcl
39+
kind: hcl
40+
sourceid: latestVersion
41+
spec:
42+
file: docker-bake.hcl
43+
path: variable.JENKINS_VERSION.default
44+
updateJenkinsVersionInDockerfiles:
45+
name: Update value of JENKINS_VERSION in Dockerfile
46+
kind: dockerfile
47+
sourceid: latestVersion
48+
spec:
49+
files:
50+
- alpine/hotspot/Dockerfile
51+
- debian/Dockerfile
52+
- rhel/Dockerfile
53+
- windows/windowsservercore/hotspot/Dockerfile
54+
instruction:
55+
keyword: ARG
56+
matcher: JENKINS_VERSION
57+
updateJenkinsVersionInGoldenFiles:
58+
kind: file
59+
sourceid: latestVersion
60+
name: Update value of JENKINS_VERSION in (weekly) golden files
61+
spec:
62+
files:
63+
- tests/golden/expected_tags.txt
64+
- tests/golden/expected_tags_latest_weekly.txt
65+
matchpattern: (\d+\.\d+)
66+
updateWarShaInDockerBake:
67+
name: Update default value of WAR_SHA in docker-bake.hcl
68+
kind: hcl
69+
sourceid: latestWarSha
70+
spec:
71+
file: docker-bake.hcl
72+
path: variable.WAR_SHA.default
73+
74+
actions:
75+
default:
76+
kind: github/pullrequest
77+
title: Bump default `JENKINS_VERSION` to {{ source "latestVersion" }}
78+
scmid: default
79+
spec:
80+
labels:
81+
- dependencies
82+
- jenkins-version

0 commit comments

Comments
 (0)