mirror of
https://github.com/photoprism/photoprism.git
synced 2026-01-23 02:24:24 +00:00
Docker: Add s6-overlay to ARMv7 and Ubuntu Jammy based images #4767
Signed-off-by: Michael Mayer <michael@photoprism.app>
This commit is contained in:
parent
0709e94e65
commit
df0c0e01a9
6 changed files with 30 additions and 27 deletions
|
|
@ -36,7 +36,9 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
GOBIN="/usr/local/bin" \
|
||||
GO111MODULE="on" \
|
||||
CGO_CFLAGS="-g -O2 -Wno-return-local-addr" \
|
||||
PROG="photoprism"
|
||||
PROG="photoprism" \
|
||||
S6_KEEP_ENV=1 \
|
||||
S6_LOGGING=0
|
||||
|
||||
# Copy scripts and package sources config.
|
||||
COPY --chown=root:root --chmod=755 /scripts/dist/ /scripts/
|
||||
|
|
@ -82,6 +84,7 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/install-s6.sh && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Download machine learning models and test data.
|
||||
|
|
@ -106,6 +109,6 @@ EXPOSE 2342 2343 2442 2443 9515 40000
|
|||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# Keep container running.
|
||||
CMD ["tail", "-f", "/dev/null"]
|
||||
|
||||
# Set default entrypoint and command.
|
||||
ENTRYPOINT ["/init"]
|
||||
CMD ["/scripts/cmd.sh", "tail", "-f", "/dev/null"]
|
||||
|
|
|
|||
|
|
@ -31,7 +31,9 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
DEBIAN_FRONTEND="noninteractive" \
|
||||
TF_CPP_MIN_LOG_LEVEL="2" \
|
||||
MALLOC_ARENA_MAX="4" \
|
||||
PROG="photoprism"
|
||||
PROG="photoprism" \
|
||||
S6_KEEP_ENV=1 \
|
||||
S6_LOGGING=0
|
||||
|
||||
# Copy scripts and package sources config.
|
||||
COPY --chown=root:root --chmod=755 /scripts/dist/ /scripts/
|
||||
|
|
@ -68,6 +70,7 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/install-s6.sh && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Set default working directory.
|
||||
|
|
@ -76,5 +79,6 @@ WORKDIR /photoprism
|
|||
# Expose HTTP and HTTPS ports.
|
||||
EXPOSE 2342 2442 2443
|
||||
|
||||
# Keep container running.
|
||||
CMD ["tail", "-f", "/dev/null"]
|
||||
# Set default entrypoint and command.
|
||||
ENTRYPOINT ["/init"]
|
||||
CMD ["/scripts/cmd.sh", "tail", "-f", "/dev/null"]
|
||||
|
|
@ -36,7 +36,9 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
GOBIN="/usr/local/bin" \
|
||||
GO111MODULE="on" \
|
||||
CGO_CFLAGS="-g -O2 -Wno-return-local-addr" \
|
||||
PROG="photoprism"
|
||||
PROG="photoprism" \
|
||||
S6_KEEP_ENV=1 \
|
||||
S6_LOGGING=0
|
||||
|
||||
# Copy scripts and package sources config.
|
||||
COPY --chown=root:root --chmod=755 /scripts/dist/ /scripts/
|
||||
|
|
@ -92,6 +94,7 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/install-s6.sh && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Download machine learning models and test data.
|
||||
|
|
@ -113,8 +116,6 @@ WORKDIR "/go/src/github.com/photoprism/photoprism"
|
|||
# - 40000 (Go Debugger)
|
||||
EXPOSE 2342 2343 2442 2443 9515 40000
|
||||
|
||||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# Keep container running.
|
||||
CMD ["tail", "-f", "/dev/null"]
|
||||
# Set default entrypoint and command.
|
||||
ENTRYPOINT ["/init"]
|
||||
CMD ["/scripts/cmd.sh", "tail", "-f", "/dev/null"]
|
||||
|
|
|
|||
|
|
@ -90,7 +90,9 @@ ENV PHOTOPRISM_ARCH=$TARGETARCH \
|
|||
PHOTOPRISM_PNG_SIZE=7680 \
|
||||
PHOTOPRISM_AUTO_INDEX="300" \
|
||||
PHOTOPRISM_AUTO_IMPORT="-1" \
|
||||
PHOTOPRISM_INIT="https"
|
||||
PHOTOPRISM_INIT="https" \
|
||||
S6_KEEP_ENV=1 \
|
||||
S6_LOGGING=0
|
||||
|
||||
# Copy dist files, scripts, and debian backports sources list.
|
||||
COPY --from=build --chown=root:root --chmod=755 /opt/photoprism/ /opt/photoprism
|
||||
|
|
@ -127,6 +129,7 @@ RUN echo 'APT::Acquire::Retries "3";' > /etc/apt/apt.conf.d/80retries && \
|
|||
/photoprism/storage/backups \
|
||||
/photoprism/storage/config \
|
||||
/photoprism/storage/cache && \
|
||||
/scripts/install-s6.sh && \
|
||||
/scripts/cleanup.sh
|
||||
|
||||
# Set default working directory.
|
||||
|
|
@ -135,8 +138,6 @@ WORKDIR /photoprism
|
|||
# Expose HTTP(S) ports.
|
||||
EXPOSE 2342 2443
|
||||
|
||||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# Start app.
|
||||
CMD ["/opt/photoprism/bin/photoprism", "start"]
|
||||
# Set default entrypoint and command.
|
||||
ENTRYPOINT ["/init"]
|
||||
CMD ["/scripts/cmd.sh", "/opt/photoprism/bin/photoprism", "start"]
|
||||
|
|
|
|||
|
|
@ -101,8 +101,5 @@ EXPOSE 2342 2443
|
|||
# Copy app files.
|
||||
COPY --from=build --chown=root:root --chmod=755 /opt/photoprism/ /opt/photoprism
|
||||
|
||||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# Start app.
|
||||
CMD ["/opt/photoprism/bin/photoprism", "start"]
|
||||
CMD ["/scripts/cmd.sh", "/opt/photoprism/bin/photoprism", "start"]
|
||||
|
|
@ -101,8 +101,5 @@ EXPOSE 2342 2443
|
|||
# Copy app files.
|
||||
COPY --from=build --chown=root:root --chmod=755 /opt/photoprism/ /opt/photoprism
|
||||
|
||||
# Declare container entrypoint script.
|
||||
ENTRYPOINT ["/scripts/entrypoint.sh"]
|
||||
|
||||
# Start app.
|
||||
CMD ["/opt/photoprism/bin/photoprism", "start"]
|
||||
CMD ["/scripts/cmd.sh", "/opt/photoprism/bin/photoprism", "start"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue