Skip to content

Instantly share code, notes, and snippets.

@0xBigBoss
Created January 6, 2025 22:53
Show Gist options
  • Save 0xBigBoss/dc36aed3f422a0b5b9752ea99cab4bb0 to your computer and use it in GitHub Desktop.
Save 0xBigBoss/dc36aed3f422a0b5b9752ea99cab4bb0 to your computer and use it in GitHub Desktop.
Connect k3s over a Zerotier network
curl -sfL https://get.k3s.io | sh -s - \
--bind-address=0.0.0.0 \
--flannel-iface=zt12345678 \
--node-ip=10.0.0.2 \
--cluster-init
# from control plane
K3S_URL=https://10.0.0.2:6443
K3S_TOKEN=$(sudo cat /var/lib/rancher/k3s/server/node-token)
# on agent
curl -sfL https://get.k3s.io | \
K3S_URL=$K3S_URL \
K3S_TOKEN=$K3S_TOKEN \
sh -s - --node-ip=10.0.0.3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment