diff options
| author | Brad Fitzpatrick <bradfitz@tailscale.com> | 2022-03-20 13:56:17 -0700 |
|---|---|---|
| committer | Brad Fitzpatrick <bradfitz@tailscale.com> | 2022-03-20 13:56:17 -0700 |
| commit | 6d33a7b5d070eb67b8161dff45b9b05d42e98832 (patch) | |
| tree | 9ac98a6c718f80bfd23c96503f44748137bff851 | |
| parent | bfb4a4d9e9b48acc3e9de8a3b2b67f1f31143b57 (diff) | |
| download | tailscale-bradfitz/derpy_cast.tar.xz tailscale-bradfitz/derpy_cast.zip | |
tailcfg: add DERPRegion anycast fieldsbradfitz/derpy_cast
Change-Id: Id0f012a31372d5f1564059cf6b5595ace1a1ced4
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
| -rw-r--r-- | tailcfg/derpmap.go | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tailcfg/derpmap.go b/tailcfg/derpmap.go index 62564f0d6..743ec1f77 100644 --- a/tailcfg/derpmap.go +++ b/tailcfg/derpmap.go @@ -68,6 +68,20 @@ type DERPRegion struct { // away to a new region without Avoid set. Avoid bool `json:",omitempty"` + // AnycastIPv4 and AnycastIPv6, if non-empty, specify that + // this region is discoverable via Anycast STUN queries. The + // STUN responses will indicate which region replied. + // + // Why a region has any anycast address for an address family, + // the Node-specific address(es) for that address family + // in the Nodes slice should not be used for STUN. They should, + // however, be used for TCP connections. + // + // If multiple regions share an anycast address, only one STUN + // query should be sent out (per address family) for the whole + // group. + AnycastIPv4, AnycastIPv6 string `json:",omitempty"` + // Nodes are the DERP nodes running in this region, in // priority order for the current client. Client TLS // connections should ideally only go to the first entry |
