feat: add flag to disable all direct connections (#7936)

This commit is contained in:
Dean Sheather
2023-06-22 08:02:05 +10:00
committed by GitHub
parent 96f9e61ca1
commit a28d422c35
22 changed files with 369 additions and 105 deletions

View File

@ -413,6 +413,7 @@ func (r *RootCmd) Server(newAPI func(context.Context, *coderd.Options) (*coderd.
derpMap, err := tailnet.NewDERPMap(
ctx, defaultRegion, cfg.DERP.Server.STUNAddresses,
cfg.DERP.Config.URL.String(), cfg.DERP.Config.Path.String(),
cfg.DERP.Config.BlockDirect.Value(),
)
if err != nil {
return xerrors.Errorf("create derp map: %w", err)