Tailscale running on controller

Hi, I’ve successfully used it on a PFC.

Here is the command I used for installation :

docker run -d --name=tailscaled --restart unless-stopped -v /var/lib:/var/lib -v /var/lib/tailscale:/var/lib/tailscale -e TS_STATE_DIR=/var/lib/tailscale -v /dev/net/tun:/dev/net/tun -e TS_USERSPACE=0 --network=host --cap-add=NET_ADMIN --cap-add=NET_RAW tailscale/tailscale

After you check the status and get the URL to connect it to your tailscale account :

docker exec tailscaled tailscale --socket /tmp/tailscaled.sock status

It should connect, you can use this same command to check if it’s connected or you will see it in your dashboard.

To update the client (optional):

docker exec tailscaled tailscale update --yes

And to me the best feature is the Site-to-Site. If you want to share the network behing your controller, just add a route like this (this is the installation command except that a route is added :

docker run -d --name=tailscaled --restart unless-stopped -v /var/lib:/var/lib -v /var/lib/tailscale:/var/lib/tailscale -e TS_STATE_DIR=/var/lib/tailscale -v /dev/net/tun:/dev/net/tun -e TS_USERSPACE=0 --network=host --cap-add=NET_ADMIN --cap-add=NET_RAW -e TS_ROUTES=192.168.68.0/24
tailscale/tailscale

You’ll have to acknowledge this on your dashboard.

To install it on an Edge computer :

curl -fsSL https://tailscale.com/install.sh | sh

tailscale up

tailscale --socket /tmp/tailscaled.sock status

And if you need to set up the Site-to-Site :

echo ‘net.ipv4.ip_forward = 1’ | sudo tee -a /etc/sysctl.d/99-tailscale.conf
echo ‘net.ipv6.conf.all.forwarding = 1’ | sudo tee -a /etc/sysctl.d/99-tailscale.conf
sudo sysctl -p /etc/sysctl.d/99-tailscale.conf
sudo tailscale up --advertise-routes=192.168.68.0/24

1 Like