Fix building the docker image
This commit is contained in:
parent
986dedfa7f
commit
8474abc967
1 changed files with 18 additions and 9 deletions
27
Dockerfile
27
Dockerfile
|
@ -1,33 +1,42 @@
|
||||||
FROM alpine:3.11
|
FROM alpine:3.11
|
||||||
|
|
||||||
#Base settings
|
# Base settings
|
||||||
ENV HOME /root
|
ENV HOME /root
|
||||||
|
|
||||||
|
# Install packages
|
||||||
|
|
||||||
|
RUN apk --update --no-cache --no-progress add \
|
||||||
|
python3 python3-dev \
|
||||||
|
libffi-dev musl-dev \
|
||||||
|
gcc g++ make \
|
||||||
|
automake autoconf libtool \
|
||||||
|
openssl \
|
||||||
|
tor
|
||||||
|
|
||||||
COPY requirements.txt /root/requirements.txt
|
COPY requirements.txt /root/requirements.txt
|
||||||
|
|
||||||
#Install ZeroNet
|
RUN pip3 install -r /root/requirements.txt \
|
||||||
RUN apk --update --no-cache --no-progress add python3 python3-dev gcc libffi-dev musl-dev make tor openssl \
|
|
||||||
&& pip3 install -r /root/requirements.txt \
|
|
||||||
&& apk del python3-dev gcc libffi-dev musl-dev make \
|
&& apk del python3-dev gcc libffi-dev musl-dev make \
|
||||||
&& echo "ControlPort 9051" >> /etc/tor/torrc \
|
&& echo "ControlPort 9051" >> /etc/tor/torrc \
|
||||||
&& echo "CookieAuthentication 1" >> /etc/tor/torrc
|
&& echo "CookieAuthentication 1" >> /etc/tor/torrc
|
||||||
|
|
||||||
RUN python3 -V \
|
RUN python3 -V \
|
||||||
&& python3 -m pip list \
|
&& python3 -m pip list \
|
||||||
&& tor --version \
|
&& tor --version \
|
||||||
&& openssl version
|
&& openssl version
|
||||||
|
|
||||||
#Add Zeronet source
|
# Add Zeronet source
|
||||||
|
|
||||||
COPY . /root
|
COPY . /root
|
||||||
VOLUME /root/data
|
VOLUME /root/data
|
||||||
|
|
||||||
#Control if Tor proxy is started
|
# Control if Tor proxy is started
|
||||||
ENV ENABLE_TOR false
|
ENV ENABLE_TOR false
|
||||||
|
|
||||||
WORKDIR /root
|
WORKDIR /root
|
||||||
|
|
||||||
#Set upstart command
|
# Set upstart command
|
||||||
CMD (! ${ENABLE_TOR} || tor&) && python3 zeronet.py --ui_ip 0.0.0.0 --fileserver_port 26552
|
CMD (! ${ENABLE_TOR} || tor&) && python3 zeronet.py --ui_ip 0.0.0.0 --fileserver_port 26552
|
||||||
|
|
||||||
#Expose ports
|
# Expose ports
|
||||||
EXPOSE 43110 26552
|
EXPOSE 43110 26552
|
||||||
|
|
Loading…
Reference in a new issue