-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathDockerfile
More file actions
47 lines (42 loc) · 1.23 KB
/
Dockerfile
File metadata and controls
47 lines (42 loc) · 1.23 KB
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
36
37
38
39
40
41
42
43
44
45
46
47
FROM node:10.15.3-alpine
LABEL maintainer="RickyHao <a959695@live.com>"
RUN set -ex \
# Build environment setup
&& apk add --no-cache --virtual .build-deps \
autoconf \
automake \
build-base \
c-ares-dev \
libev-dev \
libtool \
libsodium-dev \
linux-headers \
mbedtls-dev \
pcre-dev \
git \
# Build & install
&& mkdir -p /tmp/repo \
&& git clone https://github.com/shadowsocks/shadowsocks-libev.git /tmp/repo \
&& cd /tmp/repo \
&& git submodule update --init --recursive \
&& ./autogen.sh \
&& ./configure --prefix=/usr --disable-documentation \
&& make install \
&& apk del .build-deps \
# Runtime dependencies setup
&& apk add --no-cache \
rng-tools \
$(scanelf --needed --nobanner /usr/bin/ss-* \
| awk '{ gsub(/,/, "\nso:", $2); print "so:" $2 }' \
| sort -u) \
&& rm -rf /tmp/repo
RUN apk update &&\
apk add tzdata &&\
cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime &&\
echo "Asia/Shanghai" > /etc/timezone &&\
apk del tzdata &&\
npm config set unsafe-perm true &&\
npm i -g shadowsocks-manager
EXPOSE 8888
ENTRYPOINT ["/usr/local/bin/ssmgr"]
CMD ["-c", "/root/.ssmgr/webgui.yml"]