add matplotlib and source code pro font

This commit is contained in:
Patrick Werner 2020-05-08 22:33:03 +02:00
parent 592863e68d
commit e6c8286bc4
No known key found for this signature in database
GPG Key ID: C078A3328BEC8B94
2 changed files with 13 additions and 1 deletions

View File

@ -1,11 +1,22 @@
FROM python:3.8.2-buster
ARG PELICAN_VERSION=4.2.0
ARG SOURCE_CODE_PRO_VERSION=3.006R
ARG MATPLOTLIB_VERSION=3.2.1
RUN apt update && apt upgrade -y
RUN wget https://github.com/adobe-fonts/source-sans-pro/releases/download/${SOURCE_CODE_PRO_VERSION}/source-sans-pro-${SOURCE_CODE_PRO_VERSION}.zip && \
unzip source-sans-pro-${SOURCE_CODE_PRO_VERSION}.zip && \
rm source-sans-pro-${SOURCE_CODE_PRO_VERSION}.zip && \
mkdir -p /usr/share/fonts/opentype/adobe/ && \
cp source-sans-pro-${SOURCE_CODE_PRO_VERSION}/OTF/*.otf /usr/share/fonts/opentype/adobe/ && \
rm -rf source-sans-pro-${SOURCE_CODE_PRO_VERSION} && \
fc-cache -f -v
RUN apt install -y \
texlive-base \
texlive-latex-extra \
texlive-fonts-extra \
texlive-fonts-recommended
RUN pip install pelican==4.2.0
RUN pip install pelican==${PELICAN_VERSION}
RUN pip install matplotlib==${MATPLOTLIB_VERSION}
WORKDIR /site
RUN mkdir -p /site-generated
ENTRYPOINT ["pelican", "-Dr", "-o", "/site-generated"]

View File

@ -19,3 +19,4 @@ docker run --detach \
--volume pelican_files:/usr/share/nginx/html:ro \
nginx
```
Also provides `matplotlib`, `latex` and the [Source Code Pro](https://github.com/adobe-fonts/source-code-pro) font for use with the [m.css](https://mcss.mosra.cz/themes/pelican/) Pelican theme.