2023-05-10 21:58:37 +00:00
|
|
|
FROM alpine:3.18
|
2017-01-10 01:17:07 +00:00
|
|
|
|
2018-07-11 06:38:31 +00:00
|
|
|
LABEL maintainer="Peter Dave Hello <hsu@peterdavehello.org>"
|
2018-07-11 06:39:22 +00:00
|
|
|
LABEL name="tor-socks-proxy"
|
2018-07-11 06:40:13 +00:00
|
|
|
LABEL version="latest"
|
2017-01-10 01:17:07 +00:00
|
|
|
|
2022-01-22 12:55:51 +00:00
|
|
|
RUN echo '@edge https://dl-cdn.alpinelinux.org/alpine/edge/community' >> /etc/apk/repositories && \
|
2022-09-22 05:25:43 +00:00
|
|
|
echo '@edge https://dl-cdn.alpinelinux.org/alpine/edge/testing' >> /etc/apk/repositories && \
|
2017-10-10 10:34:39 +00:00
|
|
|
apk -U upgrade && \
|
2022-09-22 05:25:43 +00:00
|
|
|
apk -v add tor@edge obfs4proxy@edge curl && \
|
2019-07-28 19:31:58 +00:00
|
|
|
chmod 700 /var/lib/tor && \
|
2019-08-09 09:30:00 +00:00
|
|
|
rm -rf /var/cache/apk/* && \
|
|
|
|
tor --version
|
2021-01-24 15:13:32 +00:00
|
|
|
COPY --chown=tor:root torrc /etc/tor/
|
2017-01-10 01:17:07 +00:00
|
|
|
|
2018-02-23 19:29:31 +00:00
|
|
|
HEALTHCHECK --timeout=10s --start-period=60s \
|
2021-07-05 11:40:59 +00:00
|
|
|
CMD curl --fail --socks5-hostname localhost:9150 -I -L 'https://www.facebookwkhpilnemxj7asaniu7vnjjbiltxjqhye3mhbshg7kx5tfyd.onion/' || exit 1
|
2018-02-23 19:29:31 +00:00
|
|
|
|
2021-01-23 09:46:23 +00:00
|
|
|
USER tor
|
|
|
|
EXPOSE 8853/udp 9150/tcp
|
2017-01-10 01:17:07 +00:00
|
|
|
|
2018-07-11 06:36:00 +00:00
|
|
|
CMD ["/usr/bin/tor", "-f", "/etc/tor/torrc"]
|