forked from blog2i2j/lafawkes.._..shadowsocks-obfs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
35 lines (28 loc) · 1.08 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# STAGE 0: INSTALL DEPENDENCIES
FROM ubuntu:20.04
ENV DEBIAN_FRONTEND=noninteractive
# STAGE 1: INSTALL SHADOWSOCKS-LIBEV
RUN apt-get update
RUN apt-get install -y shadowsocks-libev
COPY shadowsocks-config.json /etc/shadowsocks-libev/config.json
# STAGE 2: BUILD SHADOWSOCKS-LIBEV
RUN apt-get install -y --no-install-recommends build-essential autoconf libtool libssl-dev libpcre3-dev libev-dev asciidoc xmlto automake git curl
RUN git config --global http.sslVerify false
RUN cd /tmp && \
git clone https://github.com/shadowsocks/simple-obfs.git && \
cd simple-obfs && \
git submodule update --init --recursive && \
./autogen.sh && \
./configure && make && \
make install && \
cp ./src/obfs-local /usr/local/bin/ && \
cp ./src/obfs-server /usr/local/bin/
# STAGE 3: INSTALL NGINX
RUN apt-get install -y nginx nginx-extras
RUN rm /etc/nginx/sites-enabled/default
COPY default.conf /etc/nginx/conf.d/
RUN chmod +x /etc/nginx/conf.d/default.conf
# STAGE 4: ENTRIPOINTS
COPY entrypoint.sh /usr/local/bin/
RUN chmod +x /usr/local/bin/entrypoint.sh
CMD ["entrypoint.sh"]