forked from xorilog/docker-telegram
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
57 lines (48 loc) · 1.37 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
# Gathering of binary
FROM debian:12-slim as downloader
RUN apt-get update && apt-get install -y \
apt-utils \
software-properties-common \
wget \
xz-utils \
--no-install-recommends && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
RUN wget https://updates.tdesktop.com/tlinux/tsetup.4.8.4.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:12
LABEL maintainer "Christophe Boucharlat <[email protected]>"
# 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 \
libpulse0 \
gconf2 \
libdrm2 \
libice6 \
libsm6 \
libegl1-mesa-dev \
libgl1-mesa-glx \
--no-install-recommends \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
COPY --from=downloader --chown=user /usr/bin/Telegram /home/user/Telegram
WORKDIR $HOME
USER user
ENV QT_XKB_CONFIG_ROOT=/usr/share/X11/xkb
# Autorun Telegram
CMD ["/home/user/Telegram"]