forked from Tautulli/Tautulli-Docker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
173 lines (166 loc) · 3.25 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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
FROM ubuntu:18.04
# set version for s6 overlay
ARG OVERLAY_VERSION="v1.22.1.0"
ARG OVERLAY_ARCH="amd64"
ARG DEBIAN_FRONTEND=noninteractive
# environment variables
ENV PS1="$(whoami)@$(hostname):$(pwd)$ "
ENV TAUTULLI_DOCKER=True
ENV HOME="/root"
ENV TERM="xterm"
ENV TZ=UTC
RUN \
echo "**** install build packages ****" && \
apt update && apt upgrade -y
RUN apt-get install -y \
g++ \
gcc \
libffi-dev \
python3.8 \
python3.8-dev \
tar && \
echo "**** install runtime packages ****" && \
apt-get -y install \
bash \
python3-pip \
coreutils \
curl \
git \
openssl \
tar \
tzdata \
vnstat \
wget && \
echo "**** install pip packages ****" && \
pip3 install --no-cache-dir -U \
pip && \
pip3 install --no-cache-dir -U \
plexapi \
pycryptodomex \
pytz \
tzlocal \
pip-tools \
CherryPy \
Mako \
arrow \
portend \
APScheduler \
configobj \
urllib3 \
passlib \
requests \
infi.systray \
oauthlib \
xmltodict \
websocket-client \
geoip2 \
pyjwt \
logutils \
maxminddb \
cloudinary \
facebook-sdk \
python-twitter \
ipwhois \
IPy \
vnstat \
wget && \
echo "**** install pip packages ****" && \
pip3 install --no-cache-dir -U \
pip && \
pip3 install --no-cache-dir -U \
plexapi \
pycryptodomex \
pytz \
tzlocal \
pip-tools \
CherryPy \
Mako \
arrow \
portend \
APScheduler \
configobj \
urllib3 \
passlib \
requests \
infi.systray \
oauthlib \
xmltodict \
websocket-client \
geoip2 \
pyjwt \
logutils \
maxminddb \
cloudinary \
facebook-sdk \
python-twitter \
ipwhois \
IPy \
bs4 \
feedparser \
httpagentparser \
bleach \
paho-mqtt \
gntp \
PyNMA \
profilehooks \
distro \
pyopenssl && \
echo "**** add s6 overlay ****" && \
curl -o \
/tmp/s6-overlay.tar.gz -L \
"https://github.com/just-containers/s6-overlay/releases/download/${OVERLAY_VERSION}/s6-overlay-${OVERLAY_ARCH}.tar.gz" && \
tar xfz \
/tmp/s6-overlay.tar.gz -C / && \
echo "**** create abc user and make folders ****" && \
groupmod -g 1000 users && \
useradd -u 911 -U -d /config -s /bin/false abc && \
usermod -G users abc && \
mkdir -p \
/app \
/config \
/defaults && \
echo "**** cleanup ****" && \
# apt del --purge \
# build-dependencies && \
rm -rf \
/root/.cache \
/tmp/*
# add local files
COPY root/ \
bs4 \
feedparser \
httpagentparser \
bleach \
paho-mqtt \
gntp \
PyNMA \
profilehooks \
distro \
pyopenssl && \
echo "**** add s6 overlay ****" && \
curl -o \
/tmp/s6-overlay.tar.gz -L \
"https://github.com/just-containers/s6-overlay/releases/download/${OVERLAY_VERSION}/s6-overlay-${OVERLAY_ARCH}.tar.gz" && \
tar xfz \
/tmp/s6-overlay.tar.gz -C / && \
echo "**** create abc user and make folders ****" && \
groupmod -g 1000 users && \
useradd -u 911 -U -d /config -s /bin/false abc && \
usermod -G users abc && \
mkdir -p \
/app \
/config \
/defaults && \
echo "**** cleanup ****" && \
# apt del --purge \
# build-dependencies && \
rm -rf \
/root/.cache \
/tmp/*
# add local files
COPY root/ /
ENTRYPOINT ["/init"]
# ports and volumes
VOLUME /config /plex_logs
EXPOSE 8181
HEALTHCHECK --start-period=90s CMD curl -ILfSs http://localhost:8181/status > /dev/null || exit 1