mirror of
https://github.com/juanfont/headscale.git
synced 2025-03-27 16:01:00 -04:00
chore: some renaming and fix lint
This commit is contained in:
parent
c9542bf333
commit
103b069f1f
@ -220,7 +220,7 @@ func NewHeadscale(cfg *types.Config) (*Headscale, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if cfg.DERP.ServerVerifyClients {
|
if cfg.DERP.ServerVerifyClients {
|
||||||
t := http.DefaultTransport.(*http.Transport)
|
t := http.DefaultTransport.(*http.Transport) //nolint:forcetypeassert
|
||||||
t.RegisterProtocol(
|
t.RegisterProtocol(
|
||||||
derpServer.DerpVerifyScheme,
|
derpServer.DerpVerifyScheme,
|
||||||
derpServer.NewDERPVerifyTransport(app.handleVerifyRequest),
|
derpServer.NewDERPVerifyTransport(app.handleVerifyRequest),
|
||||||
|
@ -30,8 +30,10 @@ import (
|
|||||||
// server that the DERP HTTP client does not want the HTTP 101 response
|
// server that the DERP HTTP client does not want the HTTP 101 response
|
||||||
// headers and it will begin writing & reading the DERP protocol immediately
|
// headers and it will begin writing & reading the DERP protocol immediately
|
||||||
// following its HTTP request.
|
// following its HTTP request.
|
||||||
const fastStartHeader = "Derp-Fast-Start"
|
const (
|
||||||
const DerpVerifyScheme = "derp-verify"
|
fastStartHeader = "Derp-Fast-Start"
|
||||||
|
DerpVerifyScheme = "headscale-derp-verify"
|
||||||
|
)
|
||||||
|
|
||||||
type DERPServer struct {
|
type DERPServer struct {
|
||||||
serverURL string
|
serverURL string
|
||||||
|
Loading…
x
Reference in New Issue
Block a user