How to setup basic auth for Prometheus deployed on K8s cluster using yamls?

8/10/2021

How to setup basic auth for Prometheus deployed on K8s cluster using yamls??

I was able to achieve this easily when Prometheus was deployed on a host locally using tar file. But when it is deployed as a pod in K8s cluster, tried almost everything on the internet but no luck.

Any kind of help would be really appreciated!

Thanks!

-- Saurabh
kubernetes
prometheus

1 Answer

4/28/2022

I'm not sure why would official documentation work only in a vm and not container, but if it truly not work than you can use webserver to hide your web interface behind it and setup authentication on it.

-- Grekkq
Source: StackOverflow