Update Dockerfile

This commit is contained in:
Sah 2015-01-03 20:50:31 +08:00
parent e63bc98706
commit 0ce93d85e0

View file

@ -2,19 +2,22 @@ FROM ubuntu:latest
MAINTAINER Sah Lee <contact@leesah.name>
ENV BASEDIR /
# Set up building environment
RUN apt-get update
RUN apt-get install -y git-core python python-setuptools
# Get the latest code, build and install
RUN git clone https://github.com/shadowsocks/shadowsocks.git /tmp
WORKDIR /tmp/shadowsocks
RUN git clone https://github.com/shadowsocks/shadowsocks.git $BASEDIR
WORKDIR $BASEDIR/shadowsocks
RUN pwd
RUN python setup.py build
RUN python setup.py install
# Tear down building environment and delete git repository
RUN apt-get --purge autoremove -y git-core python python-setuptools
RUN rm -rf /tmp/shadowsocks
RUN rm -rf $BASEDIR/shadowsocks
# Config file can be in a separated container
ENV CONF /etc/shadowsocks.json