mirror of
https://github.com/cmehay/docker-tor-hidden-service.git
synced 2025-06-01 12:22:19 +00:00
Migrate from Pipenv to Poetry
This commit is contained in:
parent
dddf9979db
commit
caf94bc54d
14 changed files with 1109 additions and 504 deletions
22
Dockerfile
22
Dockerfile
|
@ -1,9 +1,10 @@
|
|||
FROM alpine:latest
|
||||
FROM python:3.7-alpine
|
||||
ARG tor_version
|
||||
|
||||
ENV HOME /var/lib/tor
|
||||
ENV POETRY_VIRTUALENVS_CREATE=false
|
||||
|
||||
RUN apk add --no-cache git libevent-dev openssl-dev gcc make automake ca-certificates autoconf musl-dev coreutils zlib-dev && \
|
||||
RUN apk add --no-cache git libevent-dev openssl-dev gcc make automake ca-certificates autoconf musl-dev coreutils libffi-dev zlib-dev && \
|
||||
mkdir -p /usr/local/src/ && \
|
||||
git clone https://git.torproject.org/tor.git /usr/local/src/tor && \
|
||||
cd /usr/local/src/tor && \
|
||||
|
@ -16,22 +17,19 @@ RUN apk add --no-cache git libevent-dev openssl-dev gcc make automake ca-cer
|
|||
make && make install && \
|
||||
cd .. && \
|
||||
rm -rf tor && \
|
||||
apk add --no-cache python3 python3-dev && \
|
||||
python3 -m ensurepip && \
|
||||
rm -r /usr/lib/python*/ensurepip && \
|
||||
pip3 install --upgrade pip setuptools && \
|
||||
apk del git libevent-dev openssl-dev make automake python3-dev autoconf musl-dev coreutils && \
|
||||
pip3 install --upgrade pip poetry && \
|
||||
apk del git libevent-dev openssl-dev make automake autoconf musl-dev coreutils libffi-dev && \
|
||||
apk add --no-cache libevent openssl
|
||||
|
||||
RUN mkdir -p /etc/tor/
|
||||
|
||||
COPY assets/onions /usr/local/src/onions
|
||||
COPY onions /usr/local/src/onions/onions
|
||||
COPY poetry.lock pyproject.toml /usr/local/src/onions/
|
||||
COPY assets/torrc /var/local/tor/torrc.tpl
|
||||
|
||||
|
||||
RUN cd /usr/local/src/onions && apk add --no-cache openssl-dev libffi-dev gcc python3-dev libc-dev && \
|
||||
python3 setup.py install && \
|
||||
apk del libffi-dev gcc python3-dev libc-dev openssl-dev
|
||||
RUN cd /usr/local/src/onions && apk add --no-cache openssl-dev libffi-dev gcc libc-dev && \
|
||||
poetry install --no-dev && \
|
||||
apk del libffi-dev gcc libc-dev openssl-dev
|
||||
|
||||
RUN mkdir -p ${HOME}/.tor && \
|
||||
addgroup -S -g 107 tor && \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue