Skip to content

Commit

Permalink
copy jdk from image
Browse files Browse the repository at this point in the history
  • Loading branch information
fitztrev committed Mar 31, 2024
1 parent bd69853 commit 20d37ec
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions docker/ci.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@ FROM mongo:7-jammy as dbbuilder

RUN apt update && apt install -y git python3-pip curl
RUN pip3 install pymongo requests
RUN curl -L https://github.com/adoptium/temurin21-binaries/releases/download/jdk-21.0.2%2B13/OpenJDK21U-jdk_x64_linux_hotspot_21.0.2_13.tar.gz | tar xzf - && mv jdk-21* /jdk-21
ENV PATH=/jdk-21/bin:$PATH

ENV JAVA_HOME=/opt/java/openjdk
COPY --from=eclipse-temurin:21 $JAVA_HOME $JAVA_HOME
ENV PATH="${JAVA_HOME}/bin:${PATH}"

RUN git clone --depth 1 https://github.com/lichess-org/lila-db-seed /lila-db-seed
WORKDIR /lila-db-seed
Expand Down Expand Up @@ -48,16 +50,16 @@ RUN apt update && apt install -y curl redis python3-pip && apt clean
RUN pip3 install berserk pytest

COPY --from=dbbuilder /seeded /seeded
COPY --from=dbbuilder /jdk-21 /jdk-21
COPY --from=lilawsbuilder /lila-ws/target /lila-ws/target
COPY --from=lilabuilder /lila/target /lila/target
COPY --from=lilabuilder /lila/public /lila/public
COPY --from=lilabuilder /lila/conf /lila/conf
COPY --from=node /lila/public /lila/target/universal/stage/public
COPY --from=thegeeklab/wait-for /usr/local/bin/wait-for /usr/local/bin/wait-for

ENV JAVA_HOME=/jdk-21
ENV PATH=/jdk-21/bin:$PATH
ENV JAVA_HOME=/opt/java/openjdk
COPY --from=eclipse-temurin:21 $JAVA_HOME $JAVA_HOME
ENV PATH="${JAVA_HOME}/bin:${PATH}"
ENV LANG=C.utf8

WORKDIR /lila
Expand Down

0 comments on commit 20d37ec

Please sign in to comment.