From 0fd88ba2a3274fea468e3421323c357fd20e1b1c Mon Sep 17 00:00:00 2001 From: James Date: Sat, 14 Sep 2024 12:05:52 -0400 Subject: [PATCH] Update to eclipse-temurin:21 and remove appuser (#4675) It seems this appuser wasn't being used at all, and the USER line wasn't being set to enable it. In addition, the adduser utility didn't exist in the old or updated version of temurin. This seems simpler and works. Signed-off-by: James --- docker/Dockerfile | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index e0c6614072..c5c2a9e655 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -1,4 +1,4 @@ -FROM eclipse-temurin:11 AS builder +FROM eclipse-temurin:21 AS builder WORKDIR /opt/antlr4 @@ -14,23 +14,8 @@ RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install maven git - && mvn -DskipTests install --projects tool --also-make \ && mv ./tool/target/antlr4-*-complete.jar antlr4-tool.jar -FROM eclipse-temurin:11-jre - -ARG user=appuser -ARG group=appuser -ARG uid=1000 -ARG gid=1000 - -RUN adduser \ - --disabled-password \ - --gecos "" \ - --home "$(pwd)" \ - --no-create-home \ - --uid "${uid}" \ - "${user}" +FROM eclipse-temurin:21-jre COPY --from=builder /opt/antlr4/antlr4/antlr4-tool.jar /usr/local/lib/ WORKDIR /work ENTRYPOINT ["java", "-Xmx500M", "-cp", "/usr/local/lib/antlr4-tool.jar", "org.antlr.v4.Tool"] - -