Skip to content

Commit 4a07fcd

Browse files
authored
fix: ensure local derp uses the hostname (#6559)
This broke deployments that use a custom port with an access URL. We should write a test for this!
1 parent 8b125d6 commit 4a07fcd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cli/server.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -621,7 +621,7 @@ flags, and YAML configuration. The precedence is as follows:
621621
Nodes: []*tailcfg.DERPNode{{
622622
Name: fmt.Sprintf("%db", cfg.DERP.Server.RegionID),
623623
RegionID: int(cfg.DERP.Server.RegionID.Value()),
624-
HostName: cfg.AccessURL.Host,
624+
HostName: cfg.AccessURL.Value().Hostname(),
625625
DERPPort: accessURLPort,
626626
STUNPort: -1,
627627
ForceHTTP: cfg.AccessURL.Scheme == "http",

0 commit comments

Comments
 (0)