Reverse Proxy Prometheus with Nginx

Video Lecture

Reverse Proxy Prometheus with Nginx Reverse Proxy Prometheus with Nginx

Description

One option to help secure our Prometheus server is to put it behind a reverse proxy so that we can later add SSL and an Authentication layer over the default unrestricted Prometheus web interface.

We will use Nginx.

sudo apt install nginx

CD to the Nginx sites-enabled folder

cd /etc/nginx/sites-enabled

Create a new Nginx configuration from Prometheus

sudo nano prometheus

And copy/paste the example below

server {
    listen       443;   

    location / {
        proxy_pass           http://localhost:9090/;
    }
}

Save and restart Nginx

sudo service nginx restart
sudo service nginx status