Routers, NAS and Docker
Running ZeroTier on OpenWrt, MikroTik, Synology DSM 7 and in Docker. Native NAS packages are no longer maintained; here is the recommended container way.
Routers, NAS, Docker
OpenWrt, MikroTik, Synology, anything with containers
Docker
docker run -d --name zt --restart=always --device=/dev/net/tun --net=host --cap-add=NET_ADMIN -v /opt/zerotier:/var/lib/zerotier-one zerotier/zerotier NETWORK_IDThe mounted folder holds this device's identity. Without it every new container becomes a new device and takes a place.
Synology
ZeroTier stopped maintaining its native packages for Synology, QNAP, ASUSTOR and Western Digital and recommends containers. On DSM 7 the system first needs TUN:
echo -e '#!/bin/sh -e \ninsmod /lib/modules/tun.ko' > /usr/local/etc/rc.d/tun.sh
chmod a+x /usr/local/etc/rc.d/tun.sh
/usr/local/etc/rc.d/tun.shThe rest is in this post.
OpenWrt
Install the zerotier package and put the network ID into its configuration. With it on the router nothing has to be installed on devices at home; continue with reaching home.
- Install onceon the router
- Add a static routein the console
- Devices at homeinstall nothing
- Devices outsideinstall as usual
MikroTik
RouterOS 7 has a ZeroTier package with MikroTik's own commands, for ARM models only.
The container cannot ping anyone?
Check host networking and NET_ADMIN, then whether /dev/net/tun exists.
Does upgrading the image drop the line?
For a moment. With the identity folder mounted it returns as the same device.
Pages nearby
- ZeroTier download
- ZeroTier for PC
- ZeroTier MacBook
- ZeroTier APK
- ZeroTier controller
- ZeroTier status codes
- managed route example
- ZeroTier tips
Marks: ZeroTier OpenWrt, ZeroTier Synology, ZeroTier Docker