operator icon indicating copy to clipboard operation
operator copied to clipboard

AsURL always uses HTTP URLs

Open naveenbharadwaj-nc opened this issue 1 year ago • 19 comments

Hi,

In every *_types.go, the implementation of AsURL() function returns HTTP URL. return fmt.Sprintf("http://%s.%s.svc:%s", cr.PrefixedName(), cr.Namespace, port)

I'm trying to configure TLS between victoriametrics components which means all components must be accessed via HTTPS. For example, VMAuth must invoke https://vmsingle-.... However, because of hard-coding of http, VMAuth cannot proxy requests to other components. I get following error.

remoteAddr: "10.130.252.154:59080, X-Forwarded-For: 10.230.17.71"; requestURI: /; cannot proxy the request to http://vmsingle-k8s.svc:8429: read tcp 10.130.252.164:33032->172.30.133.124:8429: read: connection reset by peer

Please fix this if its a bug or advise any work arounds.

naveenbharadwaj-nc avatar Jun 26 '24 12:06 naveenbharadwaj-nc