Closed dfa1 closed 4 years ago
Did you already tried to base your build with this image: https://hub.docker.com/_/microsoft-java-jre-headless
Alpine configuration is very lightweight:
FROM mcr.microsoft.com/java/jre-headless:11-zulu-alpine
Image size is down to 159MB now, thanks!
$ docker image ls
mcr.microsoft.com/java/jre-headless 11-zulu-alpine 247051b3aea5 13 days ago 159MB
Problem Hosh image is about 197MB. Currently we are using
docker-maven-plugin
+Dockerfile
.Solution Explore
jlink
to custom runtime image and package them with docker. May require more work regardingmodule-info.java
and splitting maven modules.Benefit Smaller docker images with only what is strictly required.