Closed lorenzo-biava closed 1 year ago
@jekkel when you got a moment, can you review https://github.com/kiwigrid/k8s-sidecar/pull/262 ? Should be pretty straightforward, but I can provide more context around the use case if needed 😉
Sorry for the delay, reviewed the PR.
Right now the SKIP_TLS_VERIFY env only has effect on the K8s API server connection.
However, the requests to Grafana cannot be customized. Even though there used to be a way to circumvent this in the past (which no longer works -- https://github.com/psf/requests/issues/6071), there should be an explicit way to skip TLS verification for Grafana (either reusing the same env SKIP_TLS_VERIFY or a separate one). Since this runs as a sidecar, the hostname (localhost) won't match even with proper CA.
Ref: https://github.com/kiwigrid/k8s-sidecar/blob/master/src/helpers.py#L130