From 35ce04dcaf23ec2842bc6ada2fcd203eb3398da5 Mon Sep 17 00:00:00 2001 From: Christian Schenk Date: Mon, 18 Feb 2019 20:52:38 +0100 Subject: [PATCH] Improvements --- Dockerfile | 3 ++- README.md | 4 ++-- entrypoint.sh | 3 +-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 3dd6d69..4c00b80 100644 --- a/Dockerfile +++ b/Dockerfile @@ -25,7 +25,8 @@ RUN miktexsetup finish \ && mpm --admin --update-db \ && mpm --admin \ --install amsfonts \ - --install biber-linux-x86_64 + --install biber-linux-x86_64 \ + && initexmf --admin --update-fndb COPY entrypoint.sh / ENTRYPOINT ["/entrypoint.sh"] diff --git a/README.md b/README.md index 6c56011..d4d42d0 100644 --- a/README.md +++ b/README.md @@ -24,9 +24,9 @@ configured to install missing files in the container directory `/miktex/.miktex`. It is recommended that you mount this directory to a Docker volume. -All commands are executed as user `miktex`. By setting the container +All commands are executed as container user `miktex`. By setting the container environment variables `MIKTEX_GID` and `MIKTEX_UID` you can assign a -gid/uid to the MiKTeX user. +group ID and a user ID. ### Example diff --git a/entrypoint.sh b/entrypoint.sh index d4fb8f2..4ed6381 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -6,7 +6,6 @@ MIKTEX_UID=${MIKTEX_UID:-1001} groupadd -g $MIKTEX_GID -o miktex useradd --shell /bin/bash -u $MIKTEX_UID -g $MIKTEX_GID -o -c "" -Md /miktex miktex -chown miktex:miktex /miktex -chown miktex:miktex /miktex/work +chown -R miktex:miktex /miktex exec gosu miktex "$@"