mirror of
https://github.com/YACReader/yacreader
synced 2025-07-18 21:14:33 -04:00
Add support for official docker images for yacreaderlibraryserver
This commit is contained in:
102
docker/Dockerfile
Normal file
102
docker/Dockerfile
Normal file
@ -0,0 +1,102 @@
|
||||
FROM ghcr.io/linuxserver/baseimage-ubuntu:noble
|
||||
|
||||
# version, it can be a TAG or a branch
|
||||
ARG YACR_VERSION="develop"
|
||||
|
||||
# env variables
|
||||
ARG DEBIAN_FRONTEND="noninteractive"
|
||||
ENV APPNAME="YACReaderLibraryServer"
|
||||
ENV HOME="/config"
|
||||
LABEL maintainer="luisangelsm"
|
||||
|
||||
# install build & runtime packages
|
||||
RUN \
|
||||
apt-get update && \
|
||||
apt-get install -y --no-install-recommends \
|
||||
build-essential \
|
||||
desktop-file-utils \
|
||||
gcc \
|
||||
g++ \
|
||||
git \
|
||||
qt6-tools-dev \
|
||||
qt6-base-dev-tools \
|
||||
qmake6 \
|
||||
qmake6-bin \
|
||||
qt6-base-dev \
|
||||
qt6-multimedia-dev \
|
||||
qt6-tools-dev-tools \
|
||||
libgl-dev \
|
||||
qt6-l10n-tools \
|
||||
libqt6opengl6-dev \
|
||||
libunarr-dev \
|
||||
qt6-declarative-dev \
|
||||
libqt6svg6-dev \
|
||||
libqt6core5compat6-dev \
|
||||
libbz2-dev \
|
||||
libglu1-mesa-dev \
|
||||
liblzma-dev \
|
||||
libqt6gui6 \
|
||||
libqt6multimedia6 \
|
||||
libqt6network6 \
|
||||
libqt6qml6 \
|
||||
libqt6quickcontrols2-6 \
|
||||
qt6-image-formats-plugins \
|
||||
libqt6sql6 \
|
||||
libqt6sql6-sqlite \
|
||||
make \
|
||||
sqlite3 \
|
||||
libsqlite3-dev \
|
||||
unzip \
|
||||
wget \
|
||||
7zip \
|
||||
7zip-rar \
|
||||
libpoppler-qt6-dev \
|
||||
zlib1g-dev && \
|
||||
ldconfig
|
||||
|
||||
|
||||
# clone YACReader repo
|
||||
RUN git clone https://github.com/YACReader/yacreader.git /src/git && \
|
||||
cd /src/git && \
|
||||
git checkout $YACR_VERSION
|
||||
|
||||
# get 7zip source
|
||||
RUN cd /src/git/compressed_archive && \
|
||||
wget "https://github.com/YACReader/yacreader-7z-deps/blob/main/7z2301-src.7z?raw=true" -O /src/git/compressed_archive/7z2301-src.7z && \
|
||||
7z x /src/git/compressed_archive/7z2301-src.7z -o/src/git/compressed_archive/lib7zip
|
||||
|
||||
# build yacrederlibraryserver
|
||||
RUN cd /src/git/YACReaderLibraryServer && \
|
||||
# qtchooser -list-versions && \
|
||||
qmake6 PREFIX=/app CONFIG+="7zip server_standalone" YACReaderLibraryServer.pro && \
|
||||
qmake6 -v && \
|
||||
make && \
|
||||
make install
|
||||
|
||||
# clean up
|
||||
RUN cd / && \
|
||||
apt-get clean && \
|
||||
apt-get purge -y build-essential g++ gcc git make qmake6 qtchooser unzip wget && \
|
||||
apt-get -y autoremove && \
|
||||
apt-get install -y --no-install-recommends \
|
||||
dos2unix \
|
||||
libqt6core5compat6-dev \
|
||||
libpoppler-qt6-dev && \
|
||||
rm -rf \
|
||||
/src \
|
||||
/tmp/* \
|
||||
/var/cache/apt \
|
||||
/var/lib/apt/lists/*
|
||||
|
||||
# set ENV
|
||||
ENV LC_ALL="en_US.UTF-8" \
|
||||
PATH="/app/bin:${PATH}"
|
||||
|
||||
# copy files
|
||||
COPY root.tar.gz /
|
||||
# Extract the contents of root.tar.gz into the / directory
|
||||
RUN tar -xvpzf /root.tar.gz -C /
|
||||
|
||||
# ports and volumes
|
||||
EXPOSE 8080
|
||||
VOLUME ["/config", "/comics"]
|
Reference in New Issue
Block a user