-
Notifications
You must be signed in to change notification settings - Fork 10
/
Dockerfile.9-alpine
50 lines (40 loc) · 1.58 KB
/
Dockerfile.9-alpine
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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# rebased/repackaged base image that only updates existing packages
FROM mbentley/alpine:latest AS tsmuxer-build
# install build dependencies
RUN apk add --no-cache build-base bzip2-static cmake file freetype-static freetype-dev g++ git libc6-compat libpng-static zlib-dev zlib-static
# copy in build script
COPY build-tsmuxer.sh /
# build tsMuxeR
RUN /build-tsmuxer.sh
# build UMS image
# rebased/repackaged base image that only updates existing packages
FROM mbentley/alpine:latest
LABEL maintainer="Matt Bentley <[email protected]>"
ENV UMSVER=9.8.3 \
UMS_PROFILE=/opt/ums/UMS.conf \
JAVA_OPTS="-XX:+UseContainerSupport"
# download and install UMS
RUN apk add --no-cache coreutils flac mediainfo mplayer openjdk8-jre vlc &&\
wget "https://github.com/UniversalMediaServer/UniversalMediaServer/releases/download/${UMSVER}/UMS-${UMSVER}-x86_64.tgz" -O /opt/UMS-${UMSVER}.tgz &&\
cd /opt &&\
tar zxf UMS-${UMSVER}.tgz &&\
rm UMS-${UMSVER}.tgz &&\
mv ums-${UMSVER} ums &&\
rm -rf /opt/ums/jre15 &&\
rm /opt/ums/linux/tsMuxeR* &&\
ln -s /usr/lib/jvm/java-1.8-openjdk/jre /opt/ums/jre15 &&\
mkdir /opt/ums/database /opt/ums/data &&\
addgroup -g 500 ums &&\
adduser -u 500 -G ums -h /opt/ums -D ums &&\
chown -R ums:ums /opt/ums &&\
rm -rf /media/* &&\
rm -rf /opt/ums/jre14
# bring over tsmuxer
COPY --from=tsmuxer-build /tsMuxer/bin/tsMuxeR /opt/ums/linux/tsMuxeR
# add the entrypoint
COPY entrypoint.sh /entrypoint.sh
WORKDIR /opt/ums
EXPOSE 1900/udp 2869 5001 9001
VOLUME ["/tmp","/opt/ums/database","/opt/ums/data"]
ENTRYPOINT ["/entrypoint.sh"]
CMD ["/opt/ums/UMS.sh"]