forked from dznetlab/docker-telegram
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
52 lines (43 loc) · 1.3 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
# Gathering of binary
FROM debian:jessie-slim as downloader
RUN apt-get update && apt-get install -y \
apt-utils \
software-properties-common \
wget \
--no-install-recommends && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# Telegram Version 1.6.2
RUN wget https://updates.tdesktop.com/tlinux/tsetup.1.6.2.tar.xz -O /tmp/telegram.tar.xz \
&& cd /tmp/ \
&& tar xvfJ /tmp/telegram.tar.xz \
&& mv /tmp/Telegram/Telegram /usr/bin/Telegram \
&& rm -rf /tmp/{telegram.tar.xz,Telegram}
# Base docker image
FROM debian:stretch
LABEL maintainer "Christophe Boucharlat <christophe.boucharlat@gmail.com>"
# Make a user
ENV HOME /home/user
RUN useradd --create-home --home-dir $HOME user \
&& chown -R user:user $HOME \
&& usermod -a -G audio,video user
# Install required deps
RUN apt-get update && apt-get install -y \
apt-utils \
dbus-x11 \
dunst \
hunspell-en-us \
python3-dbus \
software-properties-common \
libx11-xcb1 \
gconf2 \
--no-install-recommends \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
# Telegram Version 1.6.2
COPY --from=downloader /usr/bin/Telegram /usr/bin/Telegram
WORKDIR $HOME
USER user
ENV QT_XKB_CONFIG_ROOT=/usr/share/X11/xkb
# Autorun Telegram
CMD ["/usr/bin/Telegram"]