forked from linuxserver/docker-tvheadend
-
Notifications
You must be signed in to change notification settings - Fork 17
/
Dockerfile.ubuntu
48 lines (43 loc) · 1.48 KB
/
Dockerfile.ubuntu
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
# package version
ARG BASE_IMAGE
FROM $BASE_IMAGE
LABEL maintainer="wiserain"
LABEL org.opencontainers.image.source https://github.com/wiserain/docker-tvheadend
ARG DEBIAN_FRONTEND="noninteractive"
# default variables
ENV TZ="Asia/Seoul" \
EPG2XML_CONFIG="/epg2xml/epg2xml.json" \
EPG2XML_CHANNELFILE="/epg2xml/Channel.json" \
EPG2XML_XMLFILE="/epg2xml/xml/xmltv.xml"
# copy local files
COPY root/ /
RUN \
echo "**** set permissions for scripts /usr/bin ****" && \
chmod 555 /usr/bin/tv_grab_* && \
echo "**** remove irrelevant grabbers ****" && \
xargs rm -f < /tmp/tv_grab_irr.list && \
echo "**** install dependencies for epg2xml" && \
chmod 777 /tmp && \
apt-get update -yq && \
apt-get install -yq --no-install-recommends \
git \
jq \
python3 \
python3-bs4 \
python3-lxml \
python3-pip \
python3-requests \
xml-twig-tools && \
python3 -m pip install -U pip && \
echo "**** install epg2xml ****" && \
EPG2XML_VER=$(wget --no-check-certificate -O - -o /dev/null "https://api.github.com/repos/epg2xml/epg2xml/releases/latest" | awk '/tag_name/{print $4;exit}' FS='[""]') && \
python3 -m pip install "epg2xml[lxml] @ git+https://github.com/epg2xml/epg2xml.git@${EPG2XML_VER}" && \
echo "**** cleanup ****" && \
rm -rf \
/tmp/* \
/var/tmp/* \
/var/cache/* \
/var/lib/apt/lists/*
# ports and volumes
EXPOSE 9981 9982 9983
VOLUME /config /epg2xml