also use port number when checking https proxy for WebhookAuthenticator

This commit is contained in:
Ryan Richard
2024-10-11 14:49:46 -07:00
parent 4d2bbac674
commit dc195536d0
4 changed files with 121 additions and 10 deletions
@@ -510,7 +510,7 @@ func (c *webhookCacheFillerController) validateEndpoint(endpoint string, conditi
return nil, conditions, false, false
}
usingProxyForHost, err := c.proxyDetector.UsingProxyForHost(endpointHostPort.Host)
usingProxyForHost, err := c.proxyDetector.UsingProxyForHost(endpointHostPort.Endpoint())
if err != nil {
msg := fmt.Sprintf("%s: %s", "spec.endpoint URL error", err.Error())
conditions = append(conditions, &metav1.Condition{