/tailscale-exit

quick dockerfile and compose for setting up a tailscale exit node

Primary LanguageShellCreative Commons Zero v1.0 UniversalCC0-1.0

Tailscale Exit Node

This repository contains a few utilities to bring up a Tailscale exit node quickly and easily using docker and docker-compose on almost any Linux machine.

Requirements

  • docker
  • docker-compose

Usage

  1. Clone this repository
  2. Edit the auth.key file with your Tailscale auth key. To make a new auth key, go here.
  3. Run docker compose up (or docker-compose up if you're running a older version of docker/docker-compose)
  4. Wait for the Tailscale service to start
  5. Visit https://login.tailscale.com/admin/machines to approve the machine's status as an exit node (should be named exit-node, click on the "...", then "Edit route settings" then click "Use as exit node")
  6. Optionally, disable key expiry by clicking on the "..." again and then "Disable key expiry"
  7. Once you've made sure everything is working, you can stop the container by doing Ctrl+C and then docker compose down (or docker-compose down)
  8. Run it in a detached manner by doing docker compose up -d (or docker-compose up -d) and don't worry about it anymore :)

Size in filesystem

The image size, after built, is about 80MB-90MB. The folder itself (after deleting auth.key) is about 70-80KB.

Notes

  • You can delete the auth.key file after you've made sure everything is working.
  • Do not delete the config/ directory, it contains the Tailscale configuration files.
  • If you want to change the Tailscale hostname, you can do so by editing the config.sh file or just changing it on the tailscale admin panel.