2021-04-14 23:36:40 UTC
182 MB
/opt/openjdk-17
JAVA_VERSION17-ea+14
PATH/opt/openjdk-17/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
[#000] sha256:540db60ca9383eac9e418f78490994d0af424aab7bf6d0e47ac8ed4e2e9bcbba - 1.48% (2.68 MB)
[#001] sha256:a59807c90332abccc99cec67ac7e54a6f2030704f47653b41ca8d4d82301dcbd - 0.49% (907 KB)
[#002] sha256:99f4673b4883008024de99185a0fa8b4c418c4208a54a723b50b7244eeaec203 - 98.04% (178 MB)
/bin/sh -c #(nop) ADD file:8ec69d882e7f29f0652d537557160e638168550f738d0d49f90a7ef96bf31787 in /
2021-04-14 19:19:39 UTC/bin/sh -c #(nop) CMD ["/bin/sh"]
2021-04-14 23:36:27 UTC/bin/sh -c apk add --no-cache java-cacerts
2021-04-14 23:36:27 UTC/bin/sh -c #(nop) ENV JAVA_HOME=/opt/openjdk-17
2021-04-14 23:36:27 UTC/bin/sh -c #(nop) ENV PATH=/opt/openjdk-17/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
2021-04-14 23:36:28 UTC/bin/sh -c #(nop) ENV JAVA_VERSION=17-ea+14
2021-04-14 23:36:39 UTC/bin/sh -c set -eux; arch="$(apk --print-arch)"; case "$arch" in 'x86_64') downloadUrl='https://download.java.net/java/early_access/alpine/14/binaries/openjdk-17-ea+14_linux-x64-musl_bin.tar.gz'; downloadSha256='f07a1ac921333dafac1cd886ad49600ce143be7efebd32e1a02599a8a0829dd4'; ;; *) echo >&2 "error: unsupported architecture: '$arch'"; exit 1 ;; esac; wget -O openjdk.tgz "$downloadUrl"; echo "$downloadSha256 *openjdk.tgz" | sha256sum -c -; mkdir -p "$JAVA_HOME"; tar --extract --file openjdk.tgz --directory "$JAVA_HOME" --strip-components 1 --no-same-owner ; rm openjdk.tgz*; rm -rf "$JAVA_HOME/lib/security/cacerts"; ln -sT /etc/ssl/certs/java/cacerts "$JAVA_HOME/lib/security/cacerts"; java -Xshare:dump; fileEncoding="$(echo 'System.out.println(System.getProperty("file.encoding"))' | jshell -s -)"; [ "$fileEncoding" = 'UTF-8' ]; rm -rf ~/.java; javac --version; java --version
2021-04-14 23:36:40 UTC/bin/sh -c #(nop) CMD ["jshell"]
Please be careful as this will not just delete the reference but also the actual content!
For example when you have latest and v1.2.3 both pointing to the same image
the deletion of latest will also permanently remove v1.2.3.