gathering/nginx.conf.tmpl

34 lines
775 B
Cheetah

#user www-data;
events {
worker_connections 768;
}
http {
include /etc/nginx/mime.types;
server {
listen 80;
server_name {{ env "DOMAIN" }};
resolver 127.0.0.11;
location ~ ^/node_exporter(.*)$ {
auth_basic "admin";
auth_basic_user_file /etc/nginx/conf.d/.htpasswd;
proxy_pass http://{{ env "STACK_NAME" }}_node_exporter:9100$1;
}
location ~ ^/cadvisor(.*)$ {
auth_basic "admin";
auth_basic_user_file /etc/nginx/conf.d/.htpasswd;
proxy_pass http://{{ env "STACK_NAME" }}_cadvisor:8080$1;
}
location ~ ^/promtail(.*)$ {
auth_basic "admin";
auth_basic_user_file /etc/nginx/conf.d/.htpasswd;
proxy_pass http://{{ env "STACK_NAME" }}_promtail:9080$1;
}
}
}