tailscale/k8s-operator
Tom Proctor 711698f5a9
cmd/{containerboot,k8s-operator}: use state Secret for checking device auth (#16328)
Previously, the operator checked the ProxyGroup status fields for
information on how many of the proxies had successfully authed. Use
their state Secrets instead as a more reliable source of truth.

containerboot has written device_fqdn and device_ips keys to the
state Secret since inception, and pod_uid since 1.78.0, so there's
no need to use the API for that data. Read it from the state Secret
for consistency. However, to ensure we don't read data from a
previous run of containerboot, make sure we reset containerboot's
state keys on startup.

One other knock-on effect of that is ProxyGroups can briefly be
marked not Ready while a Pod is restarting. Introduce a new
ProxyGroupAvailable condition to more accurately reflect
when downstream controllers can implement flows that rely on a
ProxyGroup having at least 1 proxy Pod running.

Fixes #16327

Change-Id: I026c18e9d23e87109a471a87b8e4fb6271716a66

Signed-off-by: Tom Proctor <tomhjp@users.noreply.github.com>
2025-06-27 18:10:04 +01:00
..
api-proxy cmd/k8s-operator,k8s-operator/api-proxy: move k8s proxy code to library (#15857) 2025-05-06 14:52:16 +01:00
apis cmd/{containerboot,k8s-operator}: use state Secret for checking device auth (#16328) 2025-06-27 18:10:04 +01:00
sessionrecording net/{netx,memnet},all: add netx.DialFunc, move memnet Network impl 2025-04-08 10:07:47 -07:00
api-docs-config.yaml go.{mod,sum},tstest/tools,k8s-operator,cmd/k8s-operator: autogenerate CRD API docs (#12884) 2024-07-29 11:50:27 +01:00
api.md cmd/k8s-operator, k8s-operator: support Static Endpoints on ProxyGroups (#16115) 2025-06-27 17:12:14 +01:00
conditions_test.go cmd/k8s-operator,k8s-operator,go.{mod,sum}: publish proxy status condition for annotated services (#12463) 2024-06-18 19:01:40 +01:00
conditions.go cmd/{containerboot,k8s-operator}: use state Secret for checking device auth (#16328) 2025-06-27 18:10:04 +01:00
utils.go cmd/{k8s-operator,containerboot},k8s-operator: remove support for proxies below capver 95. (#13986) 2024-11-12 17:13:26 +00:00