first commit
This commit is contained in:
commit
c30064b531
93 files changed
+26367
No files matched your search
+36
@@ -0,0 +1,36 @@
|
||||
# syntax=docker/dockerfile:1
|
||||
|
||||
FROM rust:1-trixie AS build
|
||||
WORKDIR /build
|
||||
COPY Cargo.toml Cargo.lock build.rs ./
|
||||
COPY migrations ./migrations
|
||||
COPY langs ./langs
|
||||
COPY src ./src
|
||||
COPY web ./web
|
||||
RUN cargo build --locked --release && strip target/release/simply-dvb
|
||||
|
||||
FROM debian:trixie-slim AS runtime
|
||||
# ffmpeg – optional transcoding profiles (audio→AAC, HEVC→H.264) for browsers
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends ca-certificates ffmpeg tzdata \
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& groupadd --system --gid 10001 simply-dvb \
|
||||
&& useradd --system --uid 10001 --gid simply-dvb --home /var/lib/simply-dvb --shell /usr/sbin/nologin simply-dvb \
|
||||
&& install -d -o simply-dvb -g simply-dvb -m 0750 /var/lib/simply-dvb
|
||||
COPY --from=build /build/target/release/simply-dvb /usr/local/bin/simply-dvb
|
||||
|
||||
# Set TZ to your local zone (e.g. -e TZ=Europe/Berlin) so EPG times and recordings match.
|
||||
ENV RUST_LOG=simply_dvb=info,warn \
|
||||
SIMPLY_DVB_DATA_DIR=/var/lib/simply-dvb \
|
||||
SIMPLY_DVB_LISTEN=0.0.0.0:9980 \
|
||||
SIMPLY_DVB_STREAM_LISTEN=0.0.0.0:9981 \
|
||||
SIMPLY_DVB_HTSP_LISTEN=0.0.0.0:9982 \
|
||||
TZ=Etc/UTC
|
||||
|
||||
# Access to /dev/dvb needs the host's "video" group: docker run --group-add $(getent group video | cut -d: -f3)
|
||||
USER simply-dvb:simply-dvb
|
||||
VOLUME ["/var/lib/simply-dvb"]
|
||||
EXPOSE 9980 9981 9982
|
||||
HEALTHCHECK --interval=30s --timeout=5s CMD ["/bin/sh", "-c", "exec 3<>/dev/tcp/127.0.0.1/9980 && printf 'GET /healthz HTTP/1.0\\r\\n\\r\\n' >&3 && grep -q ok <&3"]
|
||||
ENTRYPOINT ["/usr/local/bin/simply-dvb"]
|
||||
CMD ["serve"]
|
||||
Reference in new issue
Block a user