Add Tailscale subnet router chart

Userspace-mode subnet router advertising only the node (192.168.2.218/32).
Auth key comes from OpenBao via ESO; node state is kept in a Kubernetes
Secret so the identity survives restarts.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-10-06 18:49:53 +02:00
co-authored by Claude Opus 5.5
commit a33c855c97
6 changed files with 220 additions and 0 deletions
+33
View File
@@ -0,0 +1,33 @@
# tailscale-gitops
Tailscale **subnet router** for the single-node cluster (`loki`). It joins your tailnet
as `loki-k8s` and advertises only `192.168.2.218/32`, so devices in the tailnet reach
the node - and with it all ingress hostnames (`https://<app>.smokyzone.de:30444`) - from
anywhere, without exposing anything to the internet.
Runs in userspace mode (no `privileged`, no `NET_ADMIN`, no `/dev/net/tun`). The node
identity is stored in the Kubernetes Secret `tailscale-state`, so it survives restarts.
## Setup
1. **Auth key**: Tailscale admin console -> *Settings -> Keys -> Generate auth key*.
Reusable: off, Ephemeral: off, Pre-approved: on (if offered).
2. **Store it in OpenBao** at `secret/tailscale`, key `authkey` (UI: *secret/ -> Create
secret*, path `tailscale`). ESO turns it into the Secret `tailscale-auth`.
3. Deploy via ArgoCD (`apps-in-apps` entry `tailscale`).
4. **Admin console -> Machines -> loki-k8s**:
- *Edit route settings* -> approve `192.168.2.218/32`.
- *Disable key expiry* (otherwise the node logs out after 180 days).
5. Install the Tailscale app on phone/laptop, sign in with the same account. Open
`https://jellyfin.smokyzone.de:30444` while on mobile data.
The auth key is only used for the first login. Afterwards it can expire or be revoked.
To re-register from scratch: delete the Secret `tailscale-state` and provide a new key.
## How it fits together
- DNS: the `*.smokyzone.de` records are public and resolve to `192.168.2.218` everywhere
(when the client uses a resolver that doesn't filter private IPs, e.g. 1.1.1.1).
- Routing: the Tailscale client sends traffic for `192.168.2.218` through the tunnel to
this pod, which forwards it to the node's NodePorts.
- Android: Android allows only one VPN at a time.