dockerfiles/tor-messenger/Dockerfile

54 lines
1.7 KiB
Docker
Raw Normal View History

2015-11-01 00:15:55 +01:00
# Run tor messenger in a container
#
# docker run -d \
# -v /tmp/.X11-unix:/tmp/.X11-unix \
# -e DISPLAY=unix$DISPLAY \
# jess/tor-messenger
2015-11-01 00:15:55 +01:00
#
FROM debian:stretch
2017-04-04 09:19:17 +02:00
LABEL maintainer "Christian Koep <christiankoep@gmail.com>"
2015-11-01 00:15:55 +01:00
ENV HOME /home/user
ENV LANG C.UTF-8
2017-04-04 09:19:17 +02:00
ENV TOR_VERSION 0.4.0b2
2016-09-17 19:20:04 +02:00
ENV TOR_FINGERPRINT 0xB01C8B006DA77FAA
2015-11-01 00:15:55 +01:00
RUN apt-get update && apt-get -y install \
ca-certificates \
2015-11-01 00:15:55 +01:00
curl \
dirmngr \
gnupg \
2015-11-01 00:15:55 +01:00
gxmessage \
libasound2 \
libdbus-glib-1-2 \
2016-12-01 19:18:58 +01:00
libgtk2.0-0 \
libxt6 \
tar \
xz-utils \
zenity \
--no-install-recommends \
&& rm -rf /var/lib/apt/lists/*
2015-11-01 00:15:55 +01:00
RUN useradd --create-home --home-dir $HOME user && chown -R user:user $HOME
RUN cd /tmp && \
curl -sSOL https://dist.torproject.org/tormessenger/${TOR_VERSION}/tor-messenger-linux64-${TOR_VERSION}_en-US.tar.xz && \
2017-03-08 14:46:56 +01:00
curl -sSOL https://dist.torproject.org/tormessenger/${TOR_VERSION}/sha256sums-signed-build.txt && \
curl -sSOL https://dist.torproject.org/tormessenger/${TOR_VERSION}/sha256sums-signed-build.txt.asc && \
2015-11-01 00:15:55 +01:00
mkdir ~/.gnupg && \
gpg --no-tty --keyserver pgp.mit.edu --recv-keys ${TOR_FINGERPRINT} || \
2016-12-01 19:18:58 +01:00
gpg --fingerprint --keyid-format LONG ${TOR_FINGERPRINT} | grep "Key fingerprint = E4AC D397 5427 A5BA 8450 A1BE B01C 8B00 6DA7 7FAA" && \
2017-03-08 14:46:56 +01:00
gpg --verify sha256sums-signed-build.txt.asc && \
grep $(sha256sum tor-messenger-linux64-${TOR_VERSION}_en-US.tar.xz) sha256sums-signed-build.txt && \
2015-11-01 00:15:55 +01:00
tar xfv tor-messenger-linux64-${TOR_VERSION}_en-US.tar.xz -C /usr/local/bin && \
rm -rf tor-messenger* && \
chown -R user.user /usr/local/bin/tor-messenger && \
rm -rf ~/.gnupg && \
rm -rf /tmp
2015-11-01 00:15:55 +01:00
WORKDIR $HOME
USER user
2017-04-08 21:24:09 +02:00
CMD [ "/usr/local/bin/tor-messenger/Browser/start-tor-messenger", "--verbose", "--log", "/dev/stdout" ]