2015-09-12 00:08:20 +02:00
|
|
|
# run a tor socks proxy in a container
|
|
|
|
#
|
2015-09-13 07:56:30 +02:00
|
|
|
# docker run -d \
|
|
|
|
# --restart always \
|
|
|
|
# -v /etc/localtime:/etc/localtime:ro \
|
|
|
|
# -p 9050:9050 \
|
|
|
|
# --name torproxy \
|
|
|
|
# jess/tor-proxy
|
2015-09-12 00:08:20 +02:00
|
|
|
#
|
|
|
|
FROM alpine:latest
|
|
|
|
MAINTAINER Jessica Frazelle <jess@docker.com>
|
|
|
|
|
|
|
|
# Note: Tor is only in testing repo -> http://pkgs.alpinelinux.org/packages?package=emacs&repo=all&arch=x86_64
|
2016-06-06 05:40:20 +02:00
|
|
|
RUN apk --no-cache add \
|
|
|
|
--repository http://dl-3.alpinelinux.org/alpine/edge/testing/ \
|
|
|
|
tor
|
2015-09-12 00:08:20 +02:00
|
|
|
|
|
|
|
# expose socks port
|
|
|
|
EXPOSE 9050
|
|
|
|
|
|
|
|
# copy in our torrc file
|
|
|
|
COPY torrc.default /etc/tor/torrc.default
|
|
|
|
|
|
|
|
# make sure files are owned by tor user
|
|
|
|
RUN chown -R tor /etc/tor
|
|
|
|
|
|
|
|
USER tor
|
|
|
|
|
|
|
|
ENTRYPOINT [ "tor" ]
|
|
|
|
CMD [ "-f", "/etc/tor/torrc.default" ]
|