Skip to content

Commit ab64afa

Browse files
debug 3
1 parent f428e54 commit ab64afa

File tree

1 file changed

+14
-14
lines changed

1 file changed

+14
-14
lines changed

Dockerfile

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,6 @@
22

33
ARG LATEST_VERSION
44
FROM eclipse-temurin:${LATEST_VERSION}-jdk-noble AS temurin-latest
5-
# See: Oracle docimention about script friendly download: https://docs.oracle.com/en-us/iaas/jms/doc/script-friendly-download.html
6-
# Note:
7-
# 1. Token can be created here: https://cloud.oracle.com/?tenant=ddsbxplayground&domain=datadog&region=us-ashburn-1
8-
# 2. Once created, token should be added to GitHub protected environment by repository administrator.
9-
RUN id non-root-user
10-
RUN --mount=type=secret,id=oracle_java8_token <<-EOT
11-
set -eux
12-
sudo mkdir -p /usr/lib/jvm/oracle8
13-
# turn off tracing before touching secrets
14-
set +x
15-
sudo ORACLE_JAVA8_TOKEN="$(cat /run/secrets/oracle_java8_token)"
16-
sudo curl -L --fail -H "token:${ORACLE_JAVA8_TOKEN}" https://java.oraclecloud.com/java/8/latest/jdk-8-linux-x64_bin.tar.gz | sudo tar -xvzf - -C /usr/lib/jvm/oracle8 --strip-components 1
17-
unset ORACLE_JAVA8_TOKEN
18-
EOT
195

206
# Intermediate image used to prune cruft from JDKs and squash them all.
217
FROM ubuntu:latest AS all-jdk
@@ -81,6 +67,20 @@ COPY --from=ghcr.io/graalvm/native-image-community:17-ol9 /usr/lib64/graalvm/gra
8167
COPY --from=ghcr.io/graalvm/native-image-community:21-ol9 /usr/lib64/graalvm/graalvm-community-java21 /usr/lib/jvm/graalvm21
8268
COPY --from=ghcr.io/graalvm/native-image-community:25-ol10 /usr/lib64/graalvm/graalvm-community-java25 /usr/lib/jvm/graalvm25
8369

70+
# See: Oracle docimention about script friendly download: https://docs.oracle.com/en-us/iaas/jms/doc/script-friendly-download.html
71+
# Note:
72+
# 1. Token can be created here: https://cloud.oracle.com/?tenant=ddsbxplayground&domain=datadog&region=us-ashburn-1
73+
# 2. Once created, token should be added to GitHub protected environment by repository administrator.
74+
RUN id non-root-user
75+
RUN --mount=type=secret,id=oracle_java8_token <<-EOT
76+
set -eux
77+
sudo mkdir -p /usr/lib/jvm/oracle8
78+
# turn off tracing before touching secrets
79+
set +x
80+
sudo ORACLE_JAVA8_TOKEN="$(cat /run/secrets/oracle_java8_token)"
81+
sudo curl -L --fail -H "token:${ORACLE_JAVA8_TOKEN}" https://java.oraclecloud.com/java/8/latest/jdk-8-linux-x64_bin.tar.gz | sudo tar -xvzf - -C /usr/lib/jvm/oracle8 --strip-components 1
82+
unset ORACLE_JAVA8_TOKEN
83+
EOT
8484

8585
# Remove cruft from JDKs that is not used in the build process.
8686
RUN <<-EOT

0 commit comments

Comments
 (0)