diff --git a/.drone.jsonnet b/.drone.jsonnet index 05b7f2a..c5e4325 100644 --- a/.drone.jsonnet +++ b/.drone.jsonnet @@ -141,7 +141,6 @@ local release() = { from_secret: 'DRONE_TOKEN', }, }, - fork: true, repositories: [ 'packages/awl', ], diff --git a/pkg/resolvers/resolver.go b/pkg/resolvers/resolver.go index 1bc96de..28a8998 100644 --- a/pkg/resolvers/resolver.go +++ b/pkg/resolvers/resolver.go @@ -36,7 +36,10 @@ func LoadResolver(opts *util.Options) (Resolver, error) { }, nil case opts.QUIC: opts.Logger.Info("loading DNS-over-QUIC resolver") - opts.Request.Server = net.JoinHostPort(opts.Request.Server, strconv.Itoa(opts.Request.Port)) + + if !strings.HasSuffix(opts.Request.Server, ":"+strconv.Itoa(opts.Request.Port)) { + opts.Request.Server = net.JoinHostPort(opts.Request.Server, strconv.Itoa(opts.Request.Port)) + } return &QUICResolver{ opts: opts, @@ -53,7 +56,10 @@ func LoadResolver(opts *util.Options) (Resolver, error) { }, nil default: opts.Logger.Info("loading standard/DNS-over-TLS resolver") - opts.Request.Server = net.JoinHostPort(opts.Request.Server, strconv.Itoa(opts.Request.Port)) + + if !strings.HasSuffix(opts.Request.Server, ":"+strconv.Itoa(opts.Request.Port)) { + opts.Request.Server = net.JoinHostPort(opts.Request.Server, strconv.Itoa(opts.Request.Port)) + } return &StandardResolver{ opts: opts,