Post

Staging a shared Cloudflare Tunnel connector with zero replicas and a test to prove the handoff

Staging a shared Cloudflare Tunnel connector with zero replicas and a test to prove the handoff

A new shared Cloudflare Tunnel connector called public-tunnel is now staged at zero replicas, carrying only the apex hostname stinkyboi.com plus a 404 catch-all, while the legacy octelium-public connector stays in place for Cordium and its portal. The push adds a focused offline test that asserts the new connector’s ingress rules match exactly the retained routes from the old one, and wires that test into the static-checks suite.

What the runbook documents about the staged handoff

The tailnet-ingress.md runbook now records that public-tunnel is staged at zero replicas with the retained Cloudflare routes. Its handoff reuses the existing tunnel identity and preserves the Istio origin and route restrictions for the apex, federation, Fleet, and the two public webhooks. The legacy octelium-public connector remains deployed for Cordium and its required portal, so the new connector is deliberately inert until a future cutover.

The new offline test that locks the contract

scripts/ci/public-tunnel-connector-test.py reads the ingress blocks from both connectors’ ConfigMaps via yq, compares the new connector’s routes against the retained hostname set (stinkyboi.com), and asserts the new routes equal the filtered old routes plus a single http_status:404 catch-all. It also asserts the deployment spec for public-tunnel has replicas: 0. The test is registered in static-checks.sh and in the timeout test’s expected list, so every offline run validates the staged contract before any live traffic shift.

One policy allow-list addition

The Rego policy gained a single entry in external_secret_allowed_prefixes. The diff context shows this sits near the secret prefix allow-list, but the exact value is not visible in the excerpts. This is likely the secret reference the new connector needs, and the change is an allow-list append rather than a logic change.

Where this pattern transfers to a platform team

Staging a replacement ingress component at zero replicas behind the same tunnel identity is a low-risk way to validate configuration parity before a cutover. The transferable pieces are: a declarative retained-hostname set, an offline test that diffs old vs new ingress rules and asserts replica count, and wiring that test into the mandatory static-checks gate so the contract cannot drift unnoticed. A team managing Cloudflare Tunnel or any external ingress can copy this structure—retained set, zero-replica staging, parity test, gate integration—and swap the hostname list for their own domains.

This post is licensed under CC BY 4.0 by the author.