Build: Improve Ubuntu 22.04 LTS (Jammy Jellyfish) Dockerfiles
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
parent
64b35fcaf9
commit
0f7a8dd1fc
|
@ -44,7 +44,7 @@ echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing
|
|||
|
||||
# update operating system
|
||||
apt-get update
|
||||
apt dist-upgrade 2>/dev/null
|
||||
apt upgrade 2>/dev/null
|
||||
|
||||
# install dependencies
|
||||
apt-get -qq install --no-install-recommends apt-transport-https ca-certificates \
|
||||
|
|
|
@ -1,9 +1,14 @@
|
|||
#### Base Image: Debian 12, Codename 'Bookworm'
|
||||
FROM debian:bookworm-slim
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Build Environment (ARMv7)"
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Develop (ARMv7)"
|
||||
LABEL org.opencontainers.image.description="Debian 12, Codename 'Bookworm'"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
LABEL org.opencontainers.image.source="https://github.com/photoprism/photoprism"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="develop" \
|
||||
|
@ -31,64 +37,25 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
CGO_CFLAGS="-g -O2 -Wno-return-local-addr" \
|
||||
PROG="photoprism"
|
||||
|
||||
# copy scripts and debian backports sources list
|
||||
# Copy scripts and package sources config.
|
||||
COPY --chown=root:root --chmod=755 /scripts/dist/* /scripts/
|
||||
COPY --chown=root:root --chmod=644 /docker/develop/bookworm/sources.list /etc/apt/sources.list.d/bookworm.list
|
||||
COPY --chown=root:root --chmod=644 /.my.cnf /etc/my.cnf
|
||||
|
||||
# update image and install build dependencies
|
||||
# Update base image and add dependencies.
|
||||
RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
||||
echo 'APT::Install-Recommends "false";' > /etc/apt/apt.conf.d/80recommends && \
|
||||
echo 'APT::Install-Suggests "false";' > /etc/apt/apt.conf.d/80suggests && \
|
||||
echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/80forceyes && \
|
||||
echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing && \
|
||||
apt-get update && apt-get -qq dist-upgrade && apt-get -qq install --no-install-recommends \
|
||||
apt-utils \
|
||||
gpg \
|
||||
pkg-config \
|
||||
software-properties-common \
|
||||
ca-certificates \
|
||||
build-essential \
|
||||
gcc \
|
||||
g++ \
|
||||
sudo \
|
||||
bash \
|
||||
make \
|
||||
nano \
|
||||
lsof \
|
||||
lshw \
|
||||
git \
|
||||
jq \
|
||||
git \
|
||||
zip \
|
||||
unzip \
|
||||
wget \
|
||||
curl \
|
||||
rsync \
|
||||
sqlite3 \
|
||||
chrpath \
|
||||
gettext \
|
||||
libc6-dev \
|
||||
libssl-dev \
|
||||
libxft-dev \
|
||||
libfreetype6 \
|
||||
libfreetype6-dev \
|
||||
libfontconfig1 \
|
||||
libfontconfig1-dev \
|
||||
libhdf5-serial-dev \
|
||||
libpng-dev \
|
||||
libzmq3-dev \
|
||||
libx264-dev \
|
||||
libx265-dev \
|
||||
libnss3 \
|
||||
libxtst6 \
|
||||
librsvg2-bin \
|
||||
tzdata \
|
||||
libheif-examples \
|
||||
exiftool \
|
||||
ffmpeg \
|
||||
ffmpegthumbnailer \
|
||||
libavcodec-extra \
|
||||
apt-get update && apt-get -qq upgrade && apt-get -qq install --no-install-recommends \
|
||||
apt-utils gpg pkg-config software-properties-common ca-certificates \
|
||||
build-essential gcc g++ sudo bash make nano lsof lshw git jq \
|
||||
zip unzip wget curl rsync sqlite3 chrpath gettext libc6-dev \
|
||||
libssl-dev libxft-dev libfreetype6 libfreetype6-dev libfontconfig1 \
|
||||
libfontconfig1-dev libhdf5-serial-dev libpng-dev libzmq3-dev \
|
||||
libx264-dev libx265-dev libnss3 libxtst6 librsvg2-bin tzdata \
|
||||
libheif-examples exiftool ffmpeg ffmpegthumbnailer libavcodec-extra \
|
||||
&& \
|
||||
/scripts/install-nodejs.sh && \
|
||||
/scripts/install-tensorflow.sh && \
|
||||
|
@ -101,14 +68,14 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/scripts/create-users.sh && \
|
||||
cp /scripts/heif-convert.sh /usr/local/bin/heif-convert && \
|
||||
install -d -m 0777 -o 1000 -g 1000 \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# download models and testdata
|
||||
|
@ -121,15 +88,17 @@ RUN mkdir /tmp/photoprism && \
|
|||
# set up project directory
|
||||
WORKDIR "/go/src/github.com/photoprism/photoprism"
|
||||
|
||||
# expose the following container ports:
|
||||
# Expose the following container ports:
|
||||
# - 2342 (HTTP)
|
||||
# - 2343 (Acceptance Tests)
|
||||
# - 2442 (HTTP)
|
||||
# - 2443 (HTTPS)
|
||||
# - 9515 (Chromedriver)
|
||||
# - 40000 (Go Debugger)
|
||||
EXPOSE 2342 2343 9515 40000
|
||||
EXPOSE 2342 2343 2442 2443 9515 40000
|
||||
|
||||
# set container entrypoint script
|
||||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# keep container running
|
||||
# Keep container running.
|
||||
CMD ["tail", "-f", "/dev/null"]
|
||||
|
|
|
@ -1,9 +1,14 @@
|
|||
#### Base Image: Debian 12, Codename 'Bookworm'
|
||||
FROM debian:bookworm-slim
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism"
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Base Image (Debian 12)"
|
||||
LABEL org.opencontainers.image.description="Debian 12, Codename 'Bookworm'"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
LABEL org.opencontainers.image.source="https://github.com/photoprism/photoprism"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables, see https://docs.photoprism.app/getting-started/config-options/
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="prod" \
|
||||
|
@ -26,17 +32,17 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
TF_CPP_MIN_LOG_LEVEL="2" \
|
||||
PROG="photoprism"
|
||||
|
||||
# copy scripts and debian backports sources list
|
||||
# Copy scripts and package sources config.
|
||||
COPY --chown=root:root --chmod=755 /scripts/dist/* /scripts/
|
||||
COPY --chown=root:root --chmod=644 /docker/develop/bookworm/sources.list /etc/apt/sources.list.d/bookworm.list
|
||||
|
||||
# install additional distribution packages
|
||||
# Update base image and add dependencies.
|
||||
RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
||||
echo 'APT::Install-Recommends "false";' > /etc/apt/apt.conf.d/80recommends && \
|
||||
echo 'APT::Install-Suggests "false";' > /etc/apt/apt.conf.d/80suggests && \
|
||||
echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/80forceyes && \
|
||||
echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing && \
|
||||
apt-get update && apt-get -qq dist-upgrade && \
|
||||
apt-get update && apt-get -qq upgrade && \
|
||||
apt-get -qq install \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
|
@ -63,11 +69,11 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/photoprism/storage/cache && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# define default directory and user
|
||||
# Default working directory.
|
||||
WORKDIR /photoprism
|
||||
|
||||
# expose default http port 2342
|
||||
EXPOSE 2342
|
||||
# Expose HTTP and HTTPS ports.
|
||||
EXPOSE 2342 2442 2443
|
||||
|
||||
# keep container running
|
||||
# Keep container running.
|
||||
CMD ["tail", "-f", "/dev/null"]
|
|
@ -1,9 +1,14 @@
|
|||
#### Base Image: Debian 12, Codename 'Bookworm'
|
||||
FROM debian:bookworm-slim
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Build Environment"
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Develop (Debian 12)"
|
||||
LABEL org.opencontainers.image.description="Debian 12, Codename 'Bookworm'"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
LABEL org.opencontainers.image.source="https://github.com/photoprism/photoprism"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="develop" \
|
||||
|
@ -31,34 +37,34 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
CGO_CFLAGS="-g -O2 -Wno-return-local-addr" \
|
||||
PROG="photoprism"
|
||||
|
||||
# Copy scripts and debian backports sources list.
|
||||
# Copy scripts and package sources config.
|
||||
COPY --chown=root:root --chmod=755 /scripts/dist/* /scripts/
|
||||
COPY --chown=root:root --chmod=644 /docker/develop/bookworm/sources.list /etc/apt/sources.list.d/bookworm.list
|
||||
COPY --chown=root:root --chmod=644 /.my.cnf /etc/my.cnf
|
||||
|
||||
# Update image and install build dependencies.
|
||||
# Update base image and add dependencies.
|
||||
RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
||||
echo 'APT::Install-Recommends "false";' > /etc/apt/apt.conf.d/80recommends && \
|
||||
echo 'APT::Install-Suggests "false";' > /etc/apt/apt.conf.d/80suggests && \
|
||||
echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/80forceyes && \
|
||||
echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing && \
|
||||
apt-get update && apt-get -qq dist-upgrade && \
|
||||
apt-get update && apt-get -qq upgrade && \
|
||||
apt-get -qq install \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
jq lsof lshw sqlite3 mariadb-client imagemagick \
|
||||
exiftool darktable rawtherapee libheif-examples librsvg2-bin \
|
||||
ffmpeg ffmpegthumbnailer libavcodec-extra \
|
||||
libmatroska7 libdvdread8 libebml5 libgav1-bin libatomic1 \
|
||||
x264 x265 libvpx7 libwebm1 \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
jq lsof lshw sqlite3 mariadb-client imagemagick \
|
||||
exiftool darktable rawtherapee libheif-examples librsvg2-bin \
|
||||
ffmpeg ffmpegthumbnailer libavcodec-extra \
|
||||
libmatroska7 libdvdread8 libebml5 libgav1-bin libatomic1 \
|
||||
x264 x265 libvpx7 libwebm1 \
|
||||
&& \
|
||||
apt-get -qq install \
|
||||
apt-utils pkg-config software-properties-common \
|
||||
build-essential gcc g++ git gettext davfs2 chrpath apache2-utils \
|
||||
chromium chromium-driver chromium-sandbox firefox-esr \
|
||||
libx264-dev libx265-dev libvpx-dev libwebm-dev libpng-dev libxft-dev \
|
||||
libc6-dev libhdf5-serial-dev libzmq3-dev libssl-dev libnss3 \
|
||||
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev fonts-roboto \
|
||||
apt-utils pkg-config software-properties-common \
|
||||
build-essential gcc g++ git gettext davfs2 chrpath apache2-utils \
|
||||
chromium chromium-driver chromium-sandbox firefox-esr \
|
||||
libx264-dev libx265-dev libvpx-dev libwebm-dev libpng-dev libxft-dev \
|
||||
libc6-dev libhdf5-serial-dev libzmq3-dev libssl-dev libnss3 \
|
||||
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev fonts-roboto \
|
||||
&& \
|
||||
/scripts/install-nodejs.sh && \
|
||||
/scripts/install-tensorflow.sh && \
|
||||
|
@ -71,35 +77,37 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/scripts/create-users.sh && \
|
||||
cp /scripts/heif-convert.sh /usr/local/bin/heif-convert && \
|
||||
install -d -m 0777 -o 1000 -g 1000 \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# download models and testdata
|
||||
# Download models and testdata.
|
||||
RUN mkdir /tmp/photoprism && \
|
||||
wget "https://dl.photoprism.app/tensorflow/nsfw.zip?${BUILD_TAG}" -O /tmp/photoprism/nsfw.zip && \
|
||||
wget "https://dl.photoprism.app/tensorflow/nasnet.zip?${BUILD_TAG}" -O /tmp/photoprism/nasnet.zip && \
|
||||
wget "https://dl.photoprism.app/tensorflow/facenet.zip?${BUILD_TAG}" -O /tmp/photoprism/facenet.zip && \
|
||||
wget "https://dl.photoprism.app/qa/testdata.zip?${BUILD_TAG}" -O /tmp/photoprism/testdata.zip
|
||||
|
||||
# set up project directory
|
||||
# Default working directory.
|
||||
WORKDIR "/go/src/github.com/photoprism/photoprism"
|
||||
|
||||
# expose the following container ports:
|
||||
# Expose the following container ports:
|
||||
# - 2342 (HTTP)
|
||||
# - 2343 (Acceptance Tests)
|
||||
# - 2442 (HTTP)
|
||||
# - 2443 (HTTPS)
|
||||
# - 9515 (Chromedriver)
|
||||
# - 40000 (Go Debugger)
|
||||
EXPOSE 2342 2343 9515 40000
|
||||
EXPOSE 2342 2343 2442 2443 9515 40000
|
||||
|
||||
# set container entrypoint script
|
||||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# keep container running
|
||||
# Keep container running.
|
||||
CMD ["tail", "-f", "/dev/null"]
|
||||
|
|
|
@ -1,9 +1,14 @@
|
|||
#### Base Image: Debian 11, Codename 'Bullseye'
|
||||
FROM debian:bullseye-slim
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism"
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Base Image (Debian 11)"
|
||||
LABEL org.opencontainers.image.description="Debian 11, Codename 'Bullseye'"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
LABEL org.opencontainers.image.source="https://github.com/photoprism/photoprism"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables, see https://docs.photoprism.app/getting-started/config-options/
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="prod" \
|
||||
|
|
|
@ -1,8 +1,13 @@
|
|||
#### Base Image: Debian 11, Codename 'Bullseye'
|
||||
FROM golang:1-bullseye
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Build Environment"
|
||||
LABEL org.opencontainers.image.description="Debian 11, Codename 'Bullseye'"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="develop" \
|
||||
|
|
|
@ -1,6 +1,11 @@
|
|||
#### Base Image: Debian 10, Codename 'Buster'
|
||||
FROM golang:1-buster
|
||||
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Build Environment"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="develop" \
|
||||
|
|
|
@ -1,8 +1,13 @@
|
|||
#### Base Image: Ubuntu 21.10, Codename 'Impish Indri'
|
||||
FROM ubuntu:impish
|
||||
|
||||
# Open Container Initiative (OCI) Annotations
|
||||
# see https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
# Copyright © 2018 - 2022 PhotoPrism UG. All rights reserved.
|
||||
#
|
||||
# Questions? Email us at hello@photoprism.app or visit our website to learn
|
||||
# more about our team, products and services: https://photoprism.app/
|
||||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Build Environment"
|
||||
LABEL org.opencontainers.image.description="Ubuntu 21.10, Codename 'Impish Indri'"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
|
@ -11,10 +16,11 @@ LABEL org.opencontainers.image.documentation="https://docs.photoprism.app/develo
|
|||
LABEL org.opencontainers.image.authors="Michael Mayer <hello@photoprism.app>"
|
||||
LABEL org.opencontainers.image.vendor="PhotoPrism UG"
|
||||
|
||||
# Declare build parameters.
|
||||
ARG TARGETARCH
|
||||
ARG BUILD_TAG
|
||||
|
||||
# set environment variables
|
||||
# Set environment variables, see https://docs.photoprism.app/getting-started/config-options/.
|
||||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="develop" \
|
||||
|
|
|
@ -8,7 +8,7 @@ FROM ubuntu:jammy
|
|||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism"
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Base Image (Ubuntu 22.04 LTS)"
|
||||
LABEL org.opencontainers.image.description="Ubuntu 22.04 LTS (Jammy Jellyfish)"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
LABEL org.opencontainers.image.source="https://github.com/photoprism/photoprism"
|
||||
|
@ -41,15 +41,15 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
echo 'APT::Install-Suggests "false";' > /etc/apt/apt.conf.d/80suggests && \
|
||||
echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/80forceyes && \
|
||||
echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing && \
|
||||
apt-get update && apt-get -qq dist-upgrade && \
|
||||
apt-get update && apt-get -qq upgrade && \
|
||||
apt-get -qq install \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
jq lsof lshw sqlite3 mariadb-client imagemagick \
|
||||
exiftool darktable rawtherapee libheif-examples librsvg2-bin \
|
||||
ffmpeg ffmpegthumbnailer libavcodec-extra \
|
||||
libmatroska7 libdvdread8 libebml5 libgav1-bin libatomic1 \
|
||||
x264 x265 libvpx7 libwebm1 \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
jq lsof lshw sqlite3 mariadb-client imagemagick \
|
||||
exiftool darktable rawtherapee libheif-examples librsvg2-bin \
|
||||
ffmpeg ffmpegthumbnailer libavcodec-extra \
|
||||
libmatroska7 libdvdread8 libebml5 libgav1-bin libatomic1 \
|
||||
x264 x265 libvpx7 libwebm1 \
|
||||
&& \
|
||||
echo 'alias ll="ls -alh"' >> /etc/skel/.bashrc && \
|
||||
echo 'export PS1="\u@$DOCKER_TAG:\w\$ "' >> /etc/skel/.bashrc && \
|
||||
|
@ -58,14 +58,14 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/scripts/create-users.sh && \
|
||||
cp /scripts/heif-convert.sh /usr/local/bin/heif-convert && \
|
||||
install -d -m 0777 -o 1000 -g 1000 \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Default working directory.
|
||||
|
|
|
@ -8,7 +8,7 @@ FROM ubuntu:jammy
|
|||
|
||||
# Add Open Container Initiative (OCI) annotations.
|
||||
# See: https://github.com/opencontainers/image-spec/blob/main/annotations.md
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Build Environment"
|
||||
LABEL org.opencontainers.image.title="PhotoPrism Develop (Ubuntu 22.04 LTS)"
|
||||
LABEL org.opencontainers.image.description="Ubuntu 22.04 LTS (Jammy Jellyfish)"
|
||||
LABEL org.opencontainers.image.url="https://hub.docker.com/repository/docker/photoprism/develop"
|
||||
LABEL org.opencontainers.image.source="https://github.com/photoprism/photoprism"
|
||||
|
@ -24,10 +24,10 @@ ARG BUILD_TAG
|
|||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="develop" \
|
||||
NODE_ENV="production" \
|
||||
PS1="\u@$DOCKER_TAG:\w\$ " \
|
||||
PATH="/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/scripts:/usr/local/go/bin:/go/bin:/opt/photoprism/bin" \
|
||||
LD_LIBRARY_PATH="/usr/local/lib:/usr/lib" \
|
||||
NODE_ENV="production" \
|
||||
DEBIAN_FRONTEND="noninteractive" \
|
||||
TMPDIR="/tmp" \
|
||||
TF_CPP_MIN_LOG_LEVEL="0" \
|
||||
|
@ -47,65 +47,25 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
echo 'APT::Install-Suggests "false";' > /etc/apt/apt.conf.d/80suggests && \
|
||||
echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/80forceyes && \
|
||||
echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing && \
|
||||
apt-get update && apt-get -qq dist-upgrade && \
|
||||
apt-get update && apt-get -qq upgrade && \
|
||||
apt-get -qq install \
|
||||
apt-utils \
|
||||
gpg \
|
||||
gpg-agent \
|
||||
pkg-config \
|
||||
software-properties-common \
|
||||
ca-certificates \
|
||||
build-essential \
|
||||
g++ \
|
||||
gcc \
|
||||
sudo \
|
||||
bash \
|
||||
make \
|
||||
nano \
|
||||
lsof \
|
||||
lshw \
|
||||
wget \
|
||||
curl \
|
||||
jq \
|
||||
git \
|
||||
zip \
|
||||
unzip \
|
||||
gettext \
|
||||
firefox \
|
||||
mariadb-client \
|
||||
davfs2 \
|
||||
chrpath \
|
||||
libc6-dev \
|
||||
libssl-dev \
|
||||
libxft-dev \
|
||||
libfreetype6 \
|
||||
libfreetype6-dev \
|
||||
libfontconfig1 \
|
||||
libfontconfig1-dev \
|
||||
libhdf5-serial-dev \
|
||||
libpng-dev \
|
||||
libzmq3-dev \
|
||||
libx264-dev \
|
||||
libx265-dev \
|
||||
libnss3 \
|
||||
libxtst6 \
|
||||
librsvg2-bin \
|
||||
rsync \
|
||||
sqlite3 \
|
||||
tzdata \
|
||||
libheif-examples \
|
||||
exiftool \
|
||||
rawtherapee \
|
||||
imagemagick \
|
||||
ffmpeg \
|
||||
ffmpegthumbnailer \
|
||||
libavcodec-extra \
|
||||
apache2-utils \
|
||||
fonts-roboto \
|
||||
npm \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
jq lsof lshw sqlite3 mariadb-client imagemagick \
|
||||
exiftool darktable rawtherapee libheif-examples librsvg2-bin \
|
||||
ffmpeg ffmpegthumbnailer libavcodec-extra \
|
||||
libmatroska7 libdvdread8 libebml5 libgav1-bin libatomic1 \
|
||||
x264 x265 libvpx7 libwebm1 \
|
||||
&& \
|
||||
apt-get -qq install \
|
||||
apt-utils pkg-config software-properties-common \
|
||||
build-essential gcc g++ git gettext davfs2 chrpath apache2-utils \
|
||||
libx264-dev libx265-dev libvpx-dev libwebm-dev libpng-dev libxft-dev \
|
||||
libc6-dev libhdf5-serial-dev libzmq3-dev libssl-dev libnss3 \
|
||||
libfreetype6 libfreetype6-dev libfontconfig1 libfontconfig1-dev fonts-roboto \
|
||||
&& \
|
||||
/scripts/install-nodejs.sh && \
|
||||
/scripts/install-tensorflow.sh && \
|
||||
/scripts/install-darktable.sh && \
|
||||
/scripts/install-chrome.sh && \
|
||||
/scripts/install-go.sh && \
|
||||
/scripts/install-go-tools.sh && \
|
||||
|
@ -116,14 +76,14 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/scripts/create-users.sh && \
|
||||
cp /scripts/heif-convert.sh /usr/local/bin/heif-convert && \
|
||||
install -d -m 0777 -o 1000 -g 1000 \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/photoprism/originals \
|
||||
/photoprism/import \
|
||||
/photoprism/storage \
|
||||
/photoprism/storage/sidecar \
|
||||
/photoprism/storage/albums \
|
||||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Download models and testdata.
|
||||
|
|
|
@ -26,6 +26,7 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
DOCKER_ENV="prod" \
|
||||
PS1="\u@$DOCKER_TAG:\w\$ " \
|
||||
PATH="/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/scripts:/opt/photoprism/bin" \
|
||||
LD_LIBRARY_PATH="/usr/local/lib:/usr/lib" \
|
||||
TMPDIR="/tmp" \
|
||||
DEBIAN_FRONTEND="noninteractive" \
|
||||
TF_CPP_MIN_LOG_LEVEL="2" \
|
||||
|
@ -87,7 +88,7 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
echo 'APT::Get::Assume-Yes "true";' > /etc/apt/apt.conf.d/80forceyes && \
|
||||
echo 'APT::Get::Fix-Missing "true";' > /etc/apt/apt.conf.d/80fixmissing && \
|
||||
mv /opt/photoprism/sbin/gosu /usr/local/sbin/gosu && \
|
||||
apt-get update && apt-get -qq dist-upgrade && apt-get -qq install --no-install-recommends \
|
||||
apt-get update && apt-get -qq upgrade && apt-get -qq install --no-install-recommends \
|
||||
libc6 ca-certificates sudo bash tzdata \
|
||||
gpg zip unzip wget curl rsync make nano \
|
||||
jq lsof lshw sqlite3 mariadb-client imagemagick \
|
||||
|
|
|
@ -76,7 +76,7 @@ COPY --chown=root:root --chmod=755 /scripts/dist/* /scripts/
|
|||
|
||||
# update pre-installed packages if needed
|
||||
RUN apt-get update && \
|
||||
apt-get -qq dist-upgrade && \
|
||||
apt-get -qq upgrade && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# define default directory and user
|
||||
|
|
|
@ -26,6 +26,7 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
DOCKER_ENV="prod" \
|
||||
PS1="\u@$DOCKER_TAG:\w\$ " \
|
||||
PATH="/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/scripts:/opt/photoprism/bin" \
|
||||
LD_LIBRARY_PATH="/usr/local/lib:/usr/lib" \
|
||||
TMPDIR="/tmp" \
|
||||
DEBIAN_FRONTEND="noninteractive" \
|
||||
TF_CPP_MIN_LOG_LEVEL="2" \
|
||||
|
|
|
@ -26,6 +26,7 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
DOCKER_ENV="prod" \
|
||||
PS1="\u@$DOCKER_TAG:\w\$ " \
|
||||
PATH="/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/scripts:/opt/photoprism/bin" \
|
||||
LD_LIBRARY_PATH="/usr/local/lib:/usr/lib" \
|
||||
TMPDIR="/tmp" \
|
||||
DEBIAN_FRONTEND="noninteractive" \
|
||||
TF_CPP_MIN_LOG_LEVEL="2" \
|
||||
|
|
|
@ -40,10 +40,10 @@ ARG BUILD_TAG
|
|||
ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
||||
DOCKER_TAG=$BUILD_TAG \
|
||||
DOCKER_ENV="prod" \
|
||||
PATH="/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin:/scripts:/opt/photoprism/bin" \
|
||||
TMPDIR="/tmp" \
|
||||
DEBIAN_FRONTEND="noninteractive" \
|
||||
TF_CPP_MIN_LOG_LEVEL="2" \
|
||||
PROG="photoprism" \
|
||||
PHOTOPRISM_ASSETS_PATH="/opt/photoprism/assets" \
|
||||
PHOTOPRISM_IMPORT_PATH="/photoprism/import" \
|
||||
PHOTOPRISM_ORIGINALS_PATH="/photoprism/originals" \
|
||||
|
@ -94,7 +94,7 @@ COPY --chown=root:root --chmod=755 /scripts/dist/* /scripts/
|
|||
|
||||
# Update pre-installed packages.
|
||||
RUN apt-get update && \
|
||||
apt-get -qq dist-upgrade && \
|
||||
apt-get -qq upgrade && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Default working directory.
|
||||
|
|
Loading…
Reference in a new issue