Update Dockerfile mkdocs setup to fix build errors

Signed-off-by: Nikolai Thingnes Leira <nikolai.thingnes.leira@soprasteria.com>
This commit is contained in:
Nikolai Thingnes Leira
2023-09-21 09:09:55 +02:00
parent f01beeff5b
commit 35d178e3cd
2 changed files with 9 additions and 10 deletions
+9 -3
View File
@@ -18,9 +18,15 @@ FROM node:18-bookworm-slim
RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \
--mount=type=cache,target=/var/lib/apt,sharing=locked \
apt-get update && \
apt-get install -y --no-install-recommends libsqlite3-dev python3 python3-pip build-essential && \
yarn config set python /usr/bin/python3 && \
pip3 install mkdocs-techdocs-core==1.1.7
apt-get install -y --no-install-recommends libsqlite3-dev python3 python3-pip python3-venv build-essential && \
yarn config set python /usr/bin/python3
# Set up a virtual environment for mkdocs-techdocs-core.
ENV VIRTUAL_ENV=/opt/venv
RUN python3 -m venv $VIRTUAL_ENV
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
RUN pip3 install mkdocs-techdocs-core==1.1.7
# From here on we use the least-privileged `node` user to run the backend.
WORKDIR /app