fixed comments

This commit is contained in:
red 2022-01-28 21:43:52 +01:00
parent 015fbce7c9
commit 467f991907
4 changed files with 6 additions and 24 deletions

View File

@ -1,19 +1,12 @@
ARG ALPINE_IMAGE=alpine
ARG ALPINE_VERSION=3.15
ARG ZT_COMMIT=eac56a2e25bbd27f77505cbd0c21b86abdfbd36b
ARG ZT_VERSION=1.8.4
FROM zyclonite/zerotier
FROM zyclonite/zerotier:latest
RUN apk add --no-cache --purge --clean-protected --update supervisor iptables \
&& mkdir -p /var/log/supervisor \
&& rm -rf /var/cache/apk/*
ENV LOG_PATH=/var/log/supervisor \
BRIDGE=false
ENV LOG_PATH=/var/log/supervisor
COPY conf /opt
COPY scripts /opt
COPY conf scripts /opt
EXPOSE 9993/udp

View File

@ -35,11 +35,9 @@ or create an empty file with the network as name
#### Bridge mode
It is the implementation of the local network bridge [paper](https://zerotier.atlassian.net/wiki/spaces/SD/pages/193134593/Bridge+your+ZeroTier+and+local+network+with+a+RaspberryPi)
To enable it, remove the host network parameter and add `Bridge=true` to environment variables.
docker run --name zerotier-one --device=/dev/net/tun -e BRIDGE=true \
docker run --name zerotier-one --device=/dev/net/tun \
--cap-add=NET_ADMIN --cap-add=SYS_ADMIN \
-v /var/lib/zerotier-one:/var/lib/zerotier-one zyclonite/zerotier-bridge
-v /var/lib/zerotier-one:/var/lib/zerotier-one zyclonite/zerotier:bridge
That will start the zero-one, establish connection and build the bridge once the `zt` interface is up.

View File

@ -25,10 +25,7 @@ spec:
containers:
- name: zerotier
image: zyclonite/zerotier-bridge:latest
env:
- name: BRIDGE
value: "true"
image: zyclonite/zerotier:bridge
resources:
limits:
memory: "128Mi"

View File

@ -5,12 +5,6 @@ set -o pipefail
set -o nounset
# set -o xtrace
echo "Checking if bridge is required..."
if [ "$BRIDGE" = "false" ]; then
echo "Bridge is not required. Exiting..."
exit 0
fi
echo "Bridge is required. Starting..."
echo "Waiting for network interface to be ready..."
while ! ifconfig | grep -q zt; do