tailcfg,net/routecheck: add NodeAttrClientSideReachabilityRouteCheck (#20169)

This patch adds a new `client-side-reachability-routecheck` node
attribute to allow admins to selectively enable background routecheck
probing on trial nodes. The current implementation is still
experimental.

It adds the routecheck.IsEnabled helper to check for the new
`client-side-reachability-routecheck` node attribute alongside the
existing `client-side-reachability` node attribute in this node’s self
capabilities. This allows administrators to turn on and off this
feature by editing the policy file.

It adds the `TS_DEBUG_FORCE_CLIENT_SIDE_REACHABILITY_ROUTECHECK`
environment variable which can be set to override the policy file.
When set to `true`, it forcibly enables this feature. And when set to
`false`, it forcibly disables it.

Updates #17366
Updates tailscale/corp#33033

Signed-off-by: Simon Law <sfllaw@tailscale.com>
This commit is contained in:
Simon Law
2026-06-25 18:22:15 -07:00
committed by GitHub
parent 9169b206be
commit 2fbd30824b
3 changed files with 36 additions and 1 deletions
+4
View File
@@ -53,6 +53,10 @@ func (e *Extension) Name() string {
// Init implements the [ipnext.Extension.Init] interface method.
func (e *Extension) Init(h ipnext.Host) error {
if routecheck.DebugForceClientSideReachabilityRoutecheck().EqualBool(false) {
return ipnext.SkipExtension
}
e.nb = nodeBackender{h}
nm, ok := e.backend.(routecheck.NetMapper)