mirror of
https://github.com/kubernetes-sigs/external-dns.git
synced 2025-08-06 09:36:58 +02:00
Merge pull request #4068 from mikkeloscar/routegroup-ipv6-compatible
Make routegroup client IPv6 compatible
This commit is contained in:
commit
4d0411349d
@ -210,7 +210,8 @@ func NewRouteGroupSource(timeout time.Duration, token, tokenPath, apiServerURL,
|
||||
apiServer := u.String()
|
||||
// strip port if well known port, because of TLS certificate match
|
||||
if u.Scheme == "https" && u.Port() == "443" {
|
||||
apiServer = "https://" + u.Hostname()
|
||||
// correctly handle IPv6 addresses by keeping surrounding `[]`.
|
||||
apiServer = "https://" + strings.TrimSuffix(u.Host, ":443")
|
||||
}
|
||||
|
||||
sc := &routeGroupSource{
|
||||
|
Loading…
Reference in New Issue
Block a user