-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
31 lines (22 loc) · 1.06 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
ARG GNUDIST=debian:stable
FROM $GNUDIST as builder
RUN cd /etc/apt/sources.list.d && sed 's/Types: deb/Types: deb-src/' debian.sources >debian-src.sources
RUN apt -qq update && apt -y install git build-essential >/dev/null
RUN apt -y build-dep minidlna >/dev/null
RUN git clone --quiet --depth 1 --single-branch https://git.code.sf.net/p/minidlna/git /usr/src/minidlna
WORKDIR /usr/src/minidlna
RUN git clone --quiet --depth 1 --single-branch https://aur.archlinux.org/minidlna-custom-icon.git /usr/src/custom-icon
RUN patch < /usr/src/custom-icon/minidlna-custom-icon.patch
RUN ./autogen.sh >autogen.log
RUN ./configure >configure.log
RUN make -j$(nproc) >make.log
RUN make install
RUN minidlnad -V
FROM $GNUDIST
ENV MINIDLNA_CONFIG /etc/minidlna.conf
ENV MINIDLNA_EXTRA_ARGS -S
RUN apt -qq update
RUN apt-cache depends minidlna | grep ' Depends: lib'|awk '{print $2}'|xargs apt -y install >/dev/null
RUN apt clean && find /var/lib/apt/lists -type f -delete
COPY --from=builder /usr/local/sbin/minidlnad /bin/
ENTRYPOINT minidlnad -S $MINIDLNA_EXTRA_ARGS -f $MINIDLNA_CONFIG