Skip to content
This repository has been archived by the owner on Jun 4, 2024. It is now read-only.

Add jdk-21 image #115

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
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
16 changes: 16 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,22 @@ def tools = [
'''
},
],
[
name: 'maven',
dockerfile: 'maven/3-jdk-21-debian.Dockerfile',
imageTag: '3-jdk-21-debian',
dependencySnapshotting: true,
testImageHook: {
sh '''
mvn -v
cat /etc/debian_version
# We explicitly approve updates of Debian to know what is going on.
grep "^11\\.8\\$" /etc/debian_version
test -e "$JAVA_HOME/bin/javac"
java -version 2>&1 | grep "openjdk version \\"21"
'''
},
],
[
name: 'sonar-scanner',
dependencySnapshotting: true,
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ used in build pipelines.
- [maven3-jdk-11-alpine](maven/)
- [maven3-jdk-11-debian](maven/)
- [maven3-jdk-17-debian](maven/)
- [maven3-jdk-21-debian](maven/)
- ~~[node12-alpine](node/)~~ (deprecated)
- ~~[node14](node/)~~ (deprecated)
- ~~[node14-browsers](node/)~~ (deprecated)
Expand Down
38 changes: 38 additions & 0 deletions maven/3-jdk-21-debian.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
FROM azul/zulu-openjdk-debian:21@sha256:b10a53a05c6fcdf4b27f83300e67e2c889883143c8164e8d8a2d0498ec254376

RUN set -ex; \
apt-get update; \
apt-get install -y \
curl \
git \
jq \
openssh-client \
procps \
wget \
zip \
# Needed for `npm install keytar` for cals-cli.
libsecret-1-dev \
python3-pip \
python3-setuptools \
python3-wheel \
; \
rm -rf /var/lib/apt/lists/*; \
\
# Install Node.
wget https://raw.githubusercontent.com/capralifecycle/buildtools-snippets/master/tools/node/install.sh -O /tmp/script.sh; \
sh /tmp/script.sh; \
rm /tmp/script.sh; \
node --version; \
npm --version; \
\
# Install Docker client.
wget https://raw.githubusercontent.com/capralifecycle/buildtools-snippets/master/tools/docker/install.sh -O- | sh; \
docker --version; \
\
# Install Maven.
wget https://raw.githubusercontent.com/capralifecycle/buildtools-snippets/master/tools/maven-3/install.sh -O- | sh; \
mvn -version; \
\
# Add a user with the UID that Jenkins will use during builds.
# This solves issues for some builds that require the user to exist.
useradd -u 1000 jenkins