-
-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[DOCKER] Latex: switch to debian base (#122)
- Loading branch information
1 parent
a033ddd
commit 115f251
Showing
2 changed files
with
59 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,32 @@ | ||
FROM alpine:3.16.0 | ||
FROM debian:11.5 | ||
|
||
LABEL org.opencontainers.image.source = "https://github.com/marco-lancini/utils" | ||
|
||
# Install packages | ||
# OPTIONAL packages: | ||
# texmf-dist-formatsextra \ | ||
# texmf-dist-pictures \ | ||
# texmf-dist-science \ | ||
RUN apk update && \ | ||
apk add --no-cache \ | ||
texlive \ | ||
texlive-xetex \ | ||
texmf-dist \ | ||
texmf-dist-latexextra \ | ||
&& rm -rf /var/cache/apk/* | ||
RUN apt update && \ | ||
apt install -y \ | ||
wget \ | ||
texlive \ | ||
texlive-xetex \ | ||
texlive-latex-recommended \ | ||
texlive-latex-extra \ | ||
texlive-fonts-extra \ | ||
&& rm -rf /var/lib/apt/lists/* | ||
|
||
RUN addgroup --gid 11111 -S app | ||
RUN adduser -s /bin/false -u 11111 -G app -S app | ||
# Install the roboto font | ||
WORKDIR /root | ||
RUN wget http://mirror.ctan.org/install/fonts/roboto.tds.zip | ||
|
||
WORKDIR /root/texmf | ||
RUN unzip /root/roboto.tds.zip && \ | ||
texhash && \ | ||
updmap-sys --enable Map=roboto.map | ||
|
||
# Create low-privilege user | ||
RUN addgroup --gid 11111 app | ||
RUN adduser --shell /bin/false --uid 11111 --gid 11111 --disabled-login app | ||
|
||
# Define workdir | ||
WORKDIR /src | ||
RUN chown -R app:app /src | ||
USER app |