forked from lucktu/n2n
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Dockerfile.dhcp
44 lines (29 loc) · 967 Bytes
/
Dockerfile.dhcp
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
ARG VERSION_B_S_rC
ARG REGISTRY_USERNAME
FROM ${REGISTRY_USERNAME}/n2n_lucktu:${VERSION_B_S_rC}
ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get -qq update
RUN apt-get -qq -y install \
apt-utils tzdata \
&& cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
&& echo "Asia/Shanghai" > /etc/timezone \
&& dpkg-reconfigure -f noninteractive tzdata
ENV TZ Asia/Shanghai
##################-----##################
##################-----##################
RUN apt-get clean && rm -rf /var/lib/apt/lists/*
COPY ./scripts/*.sh /opt/n2n/
RUN chmod a+x /opt/n2n/*
ENV MODE SUPERNODE
ENV SUPERNODE_HOST n2n.lucktu.com
ENV SUPERNODE_PORT 10086
ENV EDGE_IP 10.10.10.10
ENV EDGE_NETMASK 255.255.255.0
ENV EDGE_COMMUNITY n2n
ENV EDGE_KEY test
ENV EDGE_ENCRYPTION A3
ENV EDGE_TUN edge0
ENV N2N_ARGS "-v -f"
ENV EDGE_MAC ""
ENTRYPOINT [ "/bin/bash" , "-c" , "/opt/n2n/run.sh" ]
HEALTHCHECK --interval=20s --timeout=10s CMD /opt/n2n/n2n_healthcheck.sh