Skip to content

Commit ffa6a3a

Browse files
authored
SOLR-17445 Update Docker base image to eclipse-temurin:21-jre-noble (#3640)
1 parent 7317009 commit ffa6a3a

File tree

6 files changed

+16
-10
lines changed

6 files changed

+16
-10
lines changed

solr/CHANGES.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,8 @@ Dependency Upgrades
164164

165165
* SOLR-17631: Upgrade to Lucene 10.2.1 (Ishan Chattopadhyaya, noble, Jason Gerlowski, Eric Pugh, janhoy, Christine Poerschke)
166166

167+
* SOLR-17445: The base docker image has been upgraded from Ubuntu 22 (Jammy) to Ubuntu 24 (Noble). (Jan Høydahl)
168+
167169
Other Changes
168170
---------------------
169171

solr/docker/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ When building the image, Solr accepts arguments for customization. Currently onl
4747
- `BASE_IMAGE`: Change the base java image for Solr. This can be used to change java versions, jvms, etc.
4848

4949
```bash
50-
docker build --build-arg BASE_IMAGE=custom/jdk:17-slim -f solr-X.Y.Z/docker/Dockerfile https://www.apache.org/dyn/closer.lua/solr/X.Y.Z/solr-X.Y.Z.tgz
50+
docker build --build-arg BASE_IMAGE=custom/jdk:21-slim -f solr-X.Y.Z/docker/Dockerfile https://www.apache.org/dyn/closer.lua/solr/X.Y.Z/solr-X.Y.Z.tgz
5151
```
5252

5353
Official Image Management

solr/docker/build.gradle

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def dockerImageTagSuffix = "${ -> propertyOrEnvOrDefault("solr.docker.imageTagSu
3333
def dockerImageRepo = "${ -> propertyOrEnvOrDefault("solr.docker.imageRepo", "SOLR_DOCKER_IMAGE_REPO", "apache/solr") }"
3434
def dockerImageTag = "${ -> propertyOrEnvOrDefault("solr.docker.imageTag", "SOLR_DOCKER_IMAGE_TAG", project.version + dockerImageDistSuffix) }"
3535
def dockerImageName = "${ -> propertyOrEnvOrDefault("solr.docker.imageName", "SOLR_DOCKER_IMAGE_NAME", "${dockerImageRepo}:${dockerImageTag}${dockerImageTagSuffix}") }"
36-
def baseDockerImage = "${ -> propertyOrEnvOrDefault("solr.docker.baseImage", "SOLR_DOCKER_BASE_IMAGE", 'eclipse-temurin:' + javaVersion + '-jre-jammy') }"
36+
def baseDockerImage = "${ -> propertyOrEnvOrDefault("solr.docker.baseImage", "SOLR_DOCKER_BASE_IMAGE", 'eclipse-temurin:' + javaVersion + '-jre-noble') }"
3737
def officialDockerImageName = {String dist -> "${ -> propertyOrEnvOrDefault("solr.docker.imageName", "SOLR_DOCKER_IMAGE_NAME", "${dockerImageRepo}-official:${dockerImageTag}${distToSuffix(dist)}${dockerImageTagSuffix}") }" }
3838

3939
def releaseGpgFingerprint = "${ -> propertyOrDefault('signing.gnupg.keyName',propertyOrDefault('signing.keyId','')) }"
@@ -277,9 +277,9 @@ task createBodySnippetDockerfile(type: Copy) {
277277
outputs.file("$buildDir/snippets/Dockerfile.body.snippet")
278278
rename { name -> name.replace("template","snippet") }
279279
filteringCharset 'UTF-8'
280-
280+
281281
// NOTE: The only "templating" the Dockerfile.body supports is removing comments.
282-
//
282+
//
283283
// Any situation where it feel appropriate to add variable substitution should be reconsidered, and probably
284284
// implemented as either a build-arg or as a variable expanded in the header snippets (or both)
285285
filter( commentFilter )
@@ -289,14 +289,14 @@ ext {
289289
// NOTE: 'props' are variables that will be replaced in the respective templates,
290290
// and they must consist solely of characters matching the regex '(_|\\p{Upper})+'.
291291
// They may only be used in ARG and FROM lines, via the syntax: '_REPLACE_FOO_'
292-
// where 'FOO' is the key used in 'props' (NOTE the leading and trailing literal '_' characters)
292+
// where 'FOO' is the key used in 'props' (NOTE the leading and trailing literal '_' characters)
293293
dfLocalDetails = [
294294
name: 'Local',
295295
template: 'local',
296296
desc: 'Dockerfile used to create local Solr docker images directly from Solr release tgz file',
297297

298298
// NOTE: There should be no reason for Dockerfile.local to include unique values
299-
//
299+
//
300300
// Values identical in both Dockerfiles should use consistent names in both templates and
301301
// be defined in the task creation.
302302
props: [:]
@@ -576,7 +576,7 @@ abstract class TestDockerImageTask extends DefaultTask {
576576

577577
@Input
578578
SetProperty<String> testCasesExclude = project.objects.setProperty(String)
579-
579+
580580
@OutputDirectory
581581
abstract public DirectoryProperty getOutputDir()
582582

solr/docker/gradle-help.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ gradlew dockerBuild
1717
The docker build task accepts the following inputs, all accepted via both Environment Variables and Gradle Properties.
1818

1919
Base Docker Image: (The docker image used for the "FROM" in the Solr Dockerfile)
20-
Default: "eclipse-temurin:17-jre-jammy"
20+
Default: "eclipse-temurin:21-jre-noble"
2121
EnvVar: SOLR_DOCKER_BASE_IMAGE
2222
Gradle Property: -Psolr.docker.baseImage
2323

solr/docker/templates/Dockerfile.body.template

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020
#-# ! ! ! NO VARIABLES OR CONDITIONAL LOGIC SHOULD BE NEEDED OR USED IN THIS TEMPLATE ! ! !
2121
#-# (It exists as a 'template' solely so that this comment can exist)
2222
#-#
23-
#-# The pre-reqs for this file (which must be satisfied for any "header" pre-pended to it are that
23+
#-# The pre-reqs for this file (which must be satisfied for any "header" pre-pended to it are that
2424
#-# '/opt/solr-X.Y.Z' exists (ie: COPY'ed from the build context and/or a downloaded and unpacked solr.tgz)
2525
#-#
2626
#-#
@@ -71,7 +71,7 @@ RUN set -ex; \
7171

7272
RUN set -ex; \
7373
apt-get update; \
74-
apt-get -y --no-install-recommends install acl lsof procps wget netcat gosu tini jattach; \
74+
apt-get -y --no-install-recommends install acl lsof procps wget netcat-openbsd gosu tini jattach; \
7575
rm -rf /var/lib/apt/lists/*;
7676

7777
VOLUME /var/solr

solr/solr-ref-guide/modules/upgrade-notes/pages/major-changes-in-solr-10.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,10 @@ Nowadays, the HTTP request is available via internal APIs: `SolrQueryRequest.get
168168
=== Upgrade to Jetty 12.x
169169
Solr upgraded to Jetty 12.x from 10.x as Jetty 10 and 11 have reached end-of-life support. Jetty 12.x requires Java 17 or newer and is fully compatible with Solr's new minimum requirement of Java 21. This upgrade brings support for modern HTTP protocols and adopts the Jakarta EE 10 namespace. For more details, see https://webtide.com/jetty-12-has-arrived/.
170170

171+
=== Docker
172+
173+
The OS version of the official Docker image and provided Dockerfile has been upgraded to Ubuntu 24 (noble) from Ubuntu 22 (jammy).
174+
171175
=== Analysis and Tokenizers
172176

173177
==== PathHierarchyTokenizer Behavior Change

0 commit comments

Comments
 (0)