# docker-compose.yml
networks:
  web:
    driver: bridge

services:
  tailscale:
    network_mode: host
    image: tailscale/tailscale:latest
    hostname: linode.tailfc84fe.ts.net
    volumes:
      - /var/lib/tailscale:/var/lib/tailscale # Persistent data volume
      - /dev/net/tun:/dev/net/tun # Required for Tailscale to function
    cap_add:
      - NET_ADMIN # Required for network administration
      - SYS_ADMIN # Required for system administration
    environment:
      # - TS_AUTHKEY=tskey-auth-kudNt4td4i11CNTRL-GsLa82boyX5pis4EXi4jX5z5brQDX6gnQ
      - TS_AUTHKEY=tskey-auth-koHiorB8cj11CNTRL-dLaNRmukCWL5BurtnvU2WLDbrv4SDhVDX
      #- TS_ROUTES=192.168.1.0/24 # Optional: Specify subnet routes to advertise
      #- TS_EXTRA_ARGS=--exit-node-allow-lan-access # Optional: Allow LAN access when used as an exit node
    restart: unless-stopped
    ports:
      - "8050:8050"
