From 830be4293cc8052687a68af71043fe089ee9c5fb Mon Sep 17 00:00:00 2001 From: joao Date: Wed, 30 Nov 2022 20:12:30 -0300 Subject: [PATCH] some improves --- .gitignore | 2 +- devtools/Dockerfile | 14 ++++++++------ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/.gitignore b/.gitignore index b9e6402..103d42c 100644 --- a/.gitignore +++ b/.gitignore @@ -5,5 +5,5 @@ src/_compiled /example/ **/erl_crash.dump -lib/fy_doc/_env +lib/fython/site bootstraped diff --git a/devtools/Dockerfile b/devtools/Dockerfile index fbfaf4c..ea17847 100644 --- a/devtools/Dockerfile +++ b/devtools/Dockerfile @@ -74,17 +74,19 @@ CMD echo "Compiling $FOLDER" \ FROM base as fydoc -ENV FOLDER="MUST_BE_GIVEN" - -ENV FYDOC_PATH="/lib/fydoc" -COPY /lib/fydoc $FYDOC_PATH - # Install python to use for docs -RUN apt update && \ +RUN --mount=target=/var/lib/apt/lists,type=cache,sharing=locked \ + --mount=target=/var/cache/apt,type=cache,sharing=locked \ + apt update && \ apt install -y software-properties-common && \ add-apt-repository ppa:deadsnakes/ppa && \ apt install -y python3.9 python3-pip +ENV FOLDER="MUST_BE_GIVEN" + +ENV FYDOC_PATH="/lib/fydoc" +COPY /lib/fydoc $FYDOC_PATH + RUN pip3 install -r $FYDOC_PATH/mkdocs/requirements.txt RUN /fython exec "Core.Code.compile_project('$FYDOC_PATH')" $DESTINE_PATH