Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor: External TeX Live docker container #29

Open
wants to merge 14 commits into
base: development
Choose a base branch
from

Conversation

b0ink
Copy link

@b0ink b0ink commented Sep 10, 2024

Depends on doubtfire-lms/doubtfire-api#446

Description

This update takes the TeX Live installation out of the current dev.Dockerfile and creates a new container using the official TeX Live Docker image. This will improve the process of building and deploying the main image as it no longer requires downloading and installing TeX Live.

Similar to the main container, the texlive container is kept alive using

command: /bin/sh -c "while sleep 5000; do :; done"

in the docker-compose setup, allowing doubtfire-api to docker exec into this container without needing to spin a new container up.

The latex_build.sh script is copied from doubtfire-api into the TeX Live container, and executed in the docker exec command, which will then run lualatex.

Two additional environment variables are defined in devcontainer.env

LATEX_CONTAINER_NAME=formatif-texlive-container
LATEX_BUILD_PATH=/texlive/shell/latex_build.sh

These env variables are used in latex_run.sh, and validated in the latex_helper.rb module, which requires the name of the TeX Live container to docker exec into, and the path to where the latex_build.sh is stored on the TeX Live container, as this is defined in texlive.Dockerfile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant