-
-
Notifications
You must be signed in to change notification settings - Fork 214
/
Dockerfile
23 lines (18 loc) · 877 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
FROM alpine
ARG VERSION
ENV VERSION ${VERSION:-5.2.6}
RUN apk update
RUN apk upgrade
# RUN wget -c https://dl.webx.top/nging/v4.1.5/nging_linux_amd64.tar.gz -O /home/nging_linux_amd64.tar.gz
COPY ./dist/packed/v${VERSION}/nging_linux_amd64.tar.gz /home/nging_linux_amd64.tar.gz
RUN tar -zxvf /home/nging_linux_amd64.tar.gz -C /home
RUN rm -rf /home/nging_linux_amd64.tar.gz
WORKDIR /home/nging_linux_amd64
# VOLUME [ "/home/nging_linux_amd64/data/cache", "/home/nging_linux_amd64/data/ftpdir", "/home/nging_linux_amd64/data/logs", "/home/nging_linux_amd64/data/sm2", "/home/nging_linux_amd64/myconfig", "/home/nging_linux_amd64/public" ]
ENTRYPOINT [ "./nging" ]
CMD [ "-p", "9999", "-c", "myconfig/config.yaml" ]
# * build *
# ./build-by-xgo.sh linux_amd64 min
# docker build . -t "admpub/nging:latest"
# * test *
# docker run --rm -it -p "7770:9999" admpub/nging:latest