Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions glances.subdomain.conf.sample
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# make sure that your dns has a cname set for glances and that your glances container is not using a base url

server {
listen 443 ssl;

server_name glances.*;

include /config/nginx/ssl.conf;

client_max_body_size 0;

# enable for ldap auth, fill in ldap details in ldap.conf
#include /config/nginx/ldap.conf;

location / {
# enable the next two lines for http auth
#auth_basic "Restricted";
#auth_basic_user_file /config/nginx/.htpasswd;

# enable the next two lines for ldap auth
#auth_request /auth;
#error_page 401 =200 /login;

include /config/nginx/proxy.conf;
resolver 127.0.0.11 valid=30s;
set $upstream_glances glances;
proxy_pass http://$upstream_glances:61208;
}
}
20 changes: 20 additions & 0 deletions glances.subfolder.conf.sample
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# glances does not require a base url setting

location /glances {
return 301 $scheme://$host/glances/;
}
location ^~ /glances/ {
# enable the next two lines for http auth
#auth_basic "Restricted";
#auth_basic_user_file /config/nginx/.htpasswd;

# enable the next two lines for ldap auth, also customize and enable ldap.conf in the default conf
#auth_request /auth;
#error_page 401 =200 /login;

include /config/nginx/proxy.conf;
resolver 127.0.0.11 valid=30s;
set $upstream_glances glances;
rewrite /glances(.*) $1 break;
proxy_pass http://$upstream_glances:61208;
}