jre: change compression ratio in favour of speed
This commit is contained in:
parent
90cef9a785
commit
611ffcd15c
@ -8,12 +8,20 @@ FROM docker.io/rockdrilla/graalvm-debian:jdk-${JAVA_VERSION_MAJOR}-${IMAGE_VERSI
|
|||||||
FROM jdk as jdk-to-jre
|
FROM jdk as jdk-to-jre
|
||||||
SHELL [ "/bin/sh", "-ec" ]
|
SHELL [ "/bin/sh", "-ec" ]
|
||||||
|
|
||||||
|
ARG JAVA_VERSION_MAJOR
|
||||||
|
## modern "jlink --compress" approach
|
||||||
|
ENV JLINK_COMPRESS='zip-1'
|
||||||
|
|
||||||
RUN rm -rf /jre ; \
|
RUN rm -rf /jre ; \
|
||||||
|
if [ "${JAVA_VERSION_MAJOR}" = 17 ] ; then \
|
||||||
|
## legacy "jlink --compress" approach
|
||||||
|
JLINK_COMPRESS='1' ; \
|
||||||
|
fi ; \
|
||||||
jlink \
|
jlink \
|
||||||
--add-modules ALL-MODULE-PATH \
|
--add-modules ALL-MODULE-PATH \
|
||||||
--no-man-pages \
|
--no-man-pages \
|
||||||
--no-header-files \
|
--no-header-files \
|
||||||
--compress=1 \
|
--compress=${JLINK_COMPRESS} \
|
||||||
--output /jre \
|
--output /jre \
|
||||||
; \
|
; \
|
||||||
cd /jre ; \
|
cd /jre ; \
|
||||||
|
Loading…
Reference in New Issue
Block a user