Skip to content

Commit

Permalink
Use eclipse-temurin:23-jre-alpine as default
Browse files Browse the repository at this point in the history
  • Loading branch information
djeang committed Oct 23, 2024
1 parent ed94343 commit 0aa33ef
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
*/
public class JkDockerJvmBuild extends JkDockerBuild {

public static final String BASE_IMAGE = "eclipse-temurin";
public static final String BASE_IMAGE = "eclipse-temurin:23-jdk-alpine";

private static final Predicate<Path> CHANGING_LIB = path -> path.toString().endsWith("-SNAPSHOT.jar");

Expand All @@ -56,6 +56,7 @@ public class JkDockerJvmBuild extends JkDockerBuild {

private JkDockerJvmBuild() {
this.setBaseImage(BASE_IMAGE);
this.setAddUserTemplate(JkDockerBuild.ALPINE_ADD_USER_TEMPLATE);
this.nonRootSteps.add(this::enhance);
this.rootSteps.addNonRootMkdirs("/app", "/workdir");
this.rootSteps.add("WORKDIR /workdir");
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package _dev;

import dev.jeka.core.api.tooling.docker.JkDockerBuild;
import dev.jeka.core.api.tooling.intellij.JkIml;
import dev.jeka.core.tool.JkInjectClasspath;
import dev.jeka.core.tool.KBean;
Expand Down Expand Up @@ -33,6 +34,7 @@ protected void init() {
load(DockerKBean.class).customizeJvmImage(dockerBuild -> dockerBuild
.addAgent("io.opentelemetry.javaagent:opentelemetry-javaagent:1.32.0", "")
.setBaseImage("eclipse-temurin:21.0.1_12-jre-jammy")
.setAddUserTemplate(JkDockerBuild.TEMURIN_ADD_USER_TEMPLATE)
.nonRootSteps.addCopy(getBaseDir().resolve("jeka.properties"), "/toto.txt", false)
);
}
Expand Down

0 comments on commit 0aa33ef

Please sign in to comment.