-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
38 lines (33 loc) · 1.33 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
FROM python:3-slim-bookworm
LABEL maintainer="[email protected]"
LABEL org.opencontainers.image.authors='[email protected]'
LABEL org.opencontainers.image.url='https://github.com/mmguero/montag'
LABEL org.opencontainers.image.source='https://github.com/mmguero/montag'
LABEL org.opencontainers.image.title='mmguero/montag'
LABEL org.opencontainers.image.description='Containerized E-Book Profanity Scrubber'
ENV DEBIAN_FRONTEND noninteractive
ENV TERM xterm
ENV PYTHONUNBUFFERED 1
ENV PIP_ROOT_USER_ACTION ignore
ADD . /usr/local/src/montag-cleaner
RUN apt-get update -q && \
apt-get -y install -qq --no-install-recommends \
ca-certificates \
curl \
imagemagick \
libegl1 \
libmagic1 \
libopengl0 \
libxcb-cursor0 \
libxkbcommon0 \
python3-ebooklib \
python3-magic \
xvfb \
xz-utils && \
python3 -m ensurepip && \
python3 -m pip install --no-cache /usr/local/src/montag-cleaner && \
bash -c 'curl -sSL https://raw.githubusercontent.com/kovidgoyal/calibre/master/setup/linux-installer.py | python3 -c "import sys; main=lambda:sys.stderr.write(\"Download failed\n\"); exec(sys.stdin.read()); main()"' && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/* /var/cache/*/* /usr/local/src/montag-cleaner
ENTRYPOINT ["montag"]
CMD []