Exposure: joining the tailnet #3
Labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Blocks
Depends on
#8 Deploy kuberex on saraksh via Flux HelmRelease
mikluko/kuberex
#2 Can Rex's HTTP listener sit behind an OIDC Ingress?
mikluko/kuberex
Reference
mikluko/kuberex#3
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Map: #1
Question
How does the pod join the tailnet? The OIDC Ingress is ruled out (see the research ticket). Requirement: it joins a configured tailnet on a configured control server, defaulting to Tailscale's (
https://controlplane.tailscale.com), so Headscale or similar works without an image change.Candidates:
--tailscale,--tailscale-hostname,--tailscale-auth-key-file).rex server run --helpshows no control-URL flag; whether its tsnet honours one (env or config) is unverified.tailscaledsidecar (--login-serverconfigurable) with Rex ontailnet-serveor the tailnet address through--tailscaled-socket.The answer names the mechanism, the config knobs (control URL, hostname, tags), where the auth key and node state live (
/srv/rex, OpenBao), and who may connect (node owner or--tailnet-allow-identified).Exposure: OIDC Ingress or tailnetto Exposure: joining the tailnetFact for the control-URL requirement: the Rex binary embeds
tailscale.com/tsnetwith(*Server).getControlURLand theTS_CONTROL_URLenv knob. In tsnet that function returnsServer.ControlURL, elseTS_CONTROL_URL, elsehttps://controlplane.tailscale.com. So the built-in node (--tailscale) should followTS_CONTROL_URLwith no flag. Checked in the macOS build's strings only; not yet confirmed on the Linux package or against a non-Tailscale controller.Answer
TS_CONTROL_URLis a knob, unset by default (Tailscale's control server); Headscale is gone fromsaraksh.rex server run --tailscale. No sidecar. That tsnet honoursTS_CONTROL_URLis verified only from binary strings; the manifests ticket confirms it, with atailscaledsidecar as fallback.kuberexby default, overridable withTS_HOSTNAME.--tailscale-auth-key-file, path inTS_AUTHKEY_FILE. Onsaraksh, Secretrex-tailscalefrom an ExternalSecret on OpenBaokv/k8s/agents/rex-tailscale.--state-diron/srv/rex; restarts reuse the identity, the key is needed only at first enrollment.kuberexin the admin console right after the first enrollment.