Files
asmhatreandClaude Sonnet 5 2f88734f5d Add flags: production JVM flag cheat sheet for Spring Boot on JDK 25/27
MaxRAMPercentage vs a hardcoded -Xmx, -XX:-UseContainerSupport, the
ActiveProcessorCount lie, and which diagnostic flags are worth leaving
on in prod, verified in real Docker containers on JDK 25 and JDK 27.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
2026-10-01 04:34:04 +00:00

13 lines
606 B
Docker

# No eclipse-temurin:27-* tag exists on Docker Hub yet (checked 2026-10-01) so this
# installs the Adoptium Temurin 27 GA tarball directly onto a slim Ubuntu base.
FROM ubuntu:24.04
RUN apt-get update && apt-get install -y --no-install-recommends ca-certificates && rm -rf /var/lib/apt/lists/*
COPY temurin27.tar.gz /tmp/temurin27.tar.gz
RUN mkdir -p /opt/java && tar -xzf /tmp/temurin27.tar.gz -C /opt/java --strip-components=1 && rm /tmp/temurin27.tar.gz
ENV JAVA_HOME=/opt/java
ENV PATH=$JAVA_HOME/bin:$PATH
WORKDIR /app
COPY flags-demo.jar app.jar
EXPOSE 8080
ENTRYPOINT ["java","-jar","/app/app.jar"]