diff --git a/docker/bbpPairings.Dockerfile b/docker/bbpPairings.Dockerfile index b7be244d..b5a29c19 100644 --- a/docker/bbpPairings.Dockerfile +++ b/docker/bbpPairings.Dockerfile @@ -1,7 +1,10 @@ FROM ubuntu:focal RUN apt-get update && \ - apt-get install --yes git make g++ && \ - apt-get clean + apt-get install --yes \ + g++ \ + git \ + make \ + && apt-get clean WORKDIR /mnt diff --git a/docker/ci.Dockerfile b/docker/ci.Dockerfile index c4d292e1..e1d5a198 100644 --- a/docker/ci.Dockerfile +++ b/docker/ci.Dockerfile @@ -4,13 +4,18 @@ FROM node:22-bookworm AS node COPY repos/lila /lila COPY conf/ci.conf /lila/conf/application.conf ENV COREPACK_ENABLE_DOWNLOAD_PROMPT=0 -RUN corepack enable -RUN /lila/ui/build --clean-build --debug +RUN corepack enable \ + && /lila/ui/build --clean-build --debug ################################################################################## FROM mongo:7-jammy AS dbbuilder -RUN apt update && apt install -y python3-pip python3-venv curl && apt clean +RUN apt update \ + && apt install -y \ + curl \ + python3-pip \ + python3-venv \ + && apt clean ENV JAVA_HOME=/opt/java/openjdk COPY --from=eclipse-temurin:21-jdk $JAVA_HOME $JAVA_HOME @@ -19,9 +24,9 @@ ENV PATH="${JAVA_HOME}/bin:${PATH}" COPY repos/lila-db-seed /lila-db-seed WORKDIR /lila-db-seed -RUN mkdir /seeded -RUN mongod --fork --logpath /var/log/mongodb/mongod.log --dbpath /seeded \ - && ./spamdb/spamdb.py \ +RUN mkdir /seeded \ + && mongod --fork --logpath /var/log/mongodb/mongod.log --dbpath /seeded \ + && ./spamdb/spamdb.py \ --drop-db \ --password=password \ --su-password=password \ @@ -46,8 +51,13 @@ RUN ./lila.sh stage ################################################################################## FROM mongo:7-jammy -RUN apt update && apt install -y curl redis python3-pip && apt clean -RUN pip3 install berserk pytest +RUN apt update \ + && apt install -y \ + curl \ + python3-pip \ + redis \ + && apt clean \ + && pip3 install berserk pytest COPY --from=dbbuilder /seeded /seeded COPY --from=lilawsbuilder /lila-ws/target /lila-ws/target diff --git a/docker/python.Dockerfile b/docker/python.Dockerfile index d5376daf..0ef59a4d 100644 --- a/docker/python.Dockerfile +++ b/docker/python.Dockerfile @@ -2,7 +2,11 @@ FROM eclipse-temurin:22.0.2_9-jdk-alpine COPY --from=python:3.12.6-alpine3.20 / / -RUN pip install --upgrade pip -RUN pip install berserk pymongo requests termcolor +RUN pip install --upgrade pip \ + && pip install \ + berserk \ + pymongo \ + requests \ + termcolor WORKDIR /lila-db-seed diff --git a/docker/ui.Dockerfile b/docker/ui.Dockerfile index aeb519d4..d5dfa019 100644 --- a/docker/ui.Dockerfile +++ b/docker/ui.Dockerfile @@ -1,22 +1,20 @@ FROM node:22.9.0-bookworm-slim USER root - -RUN apt update && apt install -y git && apt clean - -RUN git config --global --add safe.directory /chessground -RUN git config --global --add safe.directory /lila -RUN git config --global --add safe.directory /pgn-viewer - ENV COREPACK_ENABLE_DOWNLOAD_PROMPT=0 -RUN corepack enable - -RUN pnpm config set store-dir /.pnpm-store -# needed for ui, chessground images -RUN mkdir -p /.cache && chmod -R 777 /.cache -# needed for api_docs -RUN mkdir -p /.npm && chmod -R 777 /.npm +RUN apt update \ + && apt install -y git \ + && apt clean \ + && git config --global --add safe.directory /chessground \ + && git config --global --add safe.directory /lila \ + && git config --global --add safe.directory /pgn-viewer \ + && corepack enable \ + && pnpm config set store-dir /.pnpm-store \ + # needed for ui, chessground images + && mkdir -p /.cache && chmod -R 777 /.cache \ + # needed for api_docs + && mkdir -p /.npm && chmod -R 777 /.npm ARG USER_ID ARG GROUP_ID