FROM ubuntu:26.04 # Il n'est pas possible d'utiliser alpine, # cela pose problème avec le script de post-install qui dépends vraiment de glibc. # Il faudrait alors partir sur une full recompilation de calibre (sans certitudes sur le bon fonctionnement). LABEL maintainer="Julien Cabillot " RUN export DEBIAN_FRONTEND="noninteractive" && \ apt-get -qq update && \ apt-get -qq --yes install python3 xvfb libfontconfig1 libxrender1 libxcomposite1 libegl1 libopengl0 libxcb-cursor0 calibre && \ ln -sf /usr/bin/python3 /usr/bin/python && \ apt-get -qq --yes clean all && \ rm -rf "/usr/share/doc/"* \ "/usr/src/"* \ "/var/cache/"* \ "/var/lib/apt/lists/"* \ "/var/log/"{apt/*,dpkg.log} \ "/tmp/"* && \ useradd -m "calibre" # TODO: ne pas faire tourner en root si possible # Add Tini ENV "TINI_VERSION" "v0.16.1" ADD "https://github.com/krallin/tini/releases/download/${TINI_VERSION}/tini" "/tini" RUN chmod +x "/tini" ENTRYPOINT ["/tini", "--"] USER "calibre" CMD [ "bash", "-c", "xvfb-run calibredb add --recurse --one-book-per-directory --library-path /export/ /ebooks/*/" ]