Dockerfile 531 B

12345678910111213141516171819202122
  1. FROM python:3.10.4-alpine
  2. RUN apk --update --no-cache --no-progress add gcc libffi-dev musl-dev make tor openssl g++ \
  3. && echo "ControlPort 9051" >> /etc/tor/torrc \
  4. && echo "CookieAuthentication 1" >> /etc/tor/torrc
  5. WORKDIR /app
  6. VOLUME /app/data
  7. COPY . .
  8. RUN python3 -m venv venv \
  9. && source venv/bin/activate \
  10. && python3 -m pip install -r requirements.txt
  11. ENV ENABLE_TOR false
  12. CMD (! ${ENABLE_TOR} || tor&) \
  13. && source venv/bin/activate \
  14. && python3 zeronet.py --ui_ip "*" --fileserver_port 26552
  15. EXPOSE 43110 26552