Skip to content

Instantly share code, notes, and snippets.

@marcusrehm
Last active May 2, 2019 18:00
Show Gist options
  • Save marcusrehm/0fe9697a335e89223e7fdec85081cf86 to your computer and use it in GitHub Desktop.
Save marcusrehm/0fe9697a335e89223e7fdec85081cf86 to your computer and use it in GitHub Desktop.
Configure Azul Zulu Openjdk11 on Alpine - Docker
# Define Java environment
RUN mkdir /usr/lib/jvm/
RUN chmod -R +x /usr/lib/jvm/
COPY /install/zulu11.31.11-ca-jdk11.0.3-linux_musl_x64.tar.gz /usr/lib/jvm/
RUN tar -xzvf /usr/lib/jvm/zulu11.31.11-ca-jdk11.0.3-linux_musl_x64.tar.gz -C /usr/lib/jvm/ \
&& ln -s /usr/lib/jvm/zulu11.31.11-ca-jdk11.0.3-linux_musl_x64 /usr/lib/jvm/default-jvm \
&& ln -s /usr/lib/jvm/default-jvm/bin/java /usr/bin/java \
&& rm /usr/lib/jvm/zulu11.31.11-ca-jdk11.0.3-linux_musl_x64.tar.gz
ENV JAVA_HOME /usr/lib/jvm/default-jvm/
ENV LD_LIBRARY_PATH /usr/lib/jvm/default-jvm/lib:/usr/lib/jvm/default-jvm/lib/server
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment