Skip to content
Snippets Groups Projects
Verified Commit f3e12df4 authored by Olivier Benz's avatar Olivier Benz
Browse files

verse: Add build arg CTAN_REPO_BUILD_LATEST

- Set CTAN_REPO to CTAN_REPO_BUILD_LATEST during build
parent 3ec57124
No related branches found
No related tags found
No related merge requests found
Pipeline #31088 passed
.env:
variables:
R_VERSION: "4.4.1"
CTAN_REPO_BUILD_LATEST: "https://mirror.init7.net/ctan/systems/texlive/tlnet"
TAG_VERSION_MAJ_MIN: "false"
TAG_VERSION_MAJ: "false"
......@@ -65,6 +66,7 @@ build:latest-linux-amd64:
docker build --pull
--build-arg BUILD_ON_IMAGE
--build-arg R_VERSION
--build-arg CTAN_REPO_BUILD_LATEST
--build-arg NCPUS=$((`nproc`/2+1))
--build-arg BUILD_START=$(date -uIseconds)
-t $CI_APP_REPO:$CI_APP_TAG-linux-amd64
......@@ -108,6 +110,7 @@ build:latest-linux-arm64v8:
docker build --pull
--build-arg BUILD_ON_IMAGE
--build-arg R_VERSION
--build-arg CTAN_REPO_BUILD_LATEST
--build-arg NCPUS=$((`nproc`/2+1))
--build-arg BUILD_START=$(date -uIseconds)
-t $CI_APP_REPO:$CI_APP_TAG-linux-arm64v8
......
......@@ -14,13 +14,13 @@ ARG BUILD_ON_IMAGE
ARG CODE_BUILTIN_EXTENSIONS_DIR
ARG QUARTO_VERSION
ARG CTAN_REPO
ARG CTAN_REPO_BUILD_LATEST
ARG BUILD_START
USER root
ENV PARENT_IMAGE=${BUILD_ON_IMAGE}:${R_VERSION} \
QUARTO_VERSION=${QUARTO_VERSION} \
CTAN_REPO=${CTAN_REPO} \
BUILD_DATE=${BUILD_START}
ENV HOME=/root \
......@@ -90,7 +90,10 @@ RUN dpkgArch="$(dpkg --print-architecture)" \
&& dpkg -i texlive-local.deb \
&& apt-get -y purge equivs \
&& apt-get -y autoremove \
## Admin-based install of TinyTeX:
## Admin-based install of TinyTeX
&& CTAN_REPO_ORIG=${CTAN_REPO} \
&& CTAN_REPO=${CTAN_REPO_BUILD_LATEST:-$CTAN_REPO} \
&& export CTAN_REPO \
&& wget -qO- "https://yihui.org/tinytex/install-unx.sh" \
| sh -s - --admin --no-path \
&& mv ${HOME}/.TinyTeX /opt/TinyTeX \
......@@ -117,6 +120,7 @@ RUN dpkgArch="$(dpkg --print-architecture)" \
oberdiek \
titling \
&& tlmgr path add \
&& tlmgr option repository ${CTAN_REPO_ORIG} \
&& Rscript -e "tinytex::r_texmf()" \
&& chown -R root:${NB_GID} /opt/TinyTeX \
&& chmod -R g+w /opt/TinyTeX \
......@@ -176,6 +180,8 @@ RUN dpkgArch="$(dpkg --print-architecture)" \
## Switch back to ${NB_USER} to avoid accidental container runs as root
USER ${NB_USER}
ENV CTAN_REPO=${CTAN_REPO}
ENV HOME=/home/${NB_USER}
WORKDIR ${HOME}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment