diff --git a/root/defaults/default b/root/defaults/default index 9ffee51..3593668 100644 --- a/root/defaults/default +++ b/root/defaults/default @@ -41,6 +41,17 @@ server { client_max_body_size 0; 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 /ldaplogin; + + # enable for Authelia + #include /config/nginx/authelia-location.conf; + try_files $uri $uri/ /index.html /index.php?$args =404; } @@ -151,3 +162,5 @@ server { # enable subdomain method reverse proxy confs include /config/nginx/proxy-confs/*.subdomain.conf; +# enable proxy cache for auth +proxy_cache_path cache/ keys_zone=auth_cache:10m; diff --git a/root/defaults/proxy.conf b/root/defaults/proxy.conf index 921fad4..b621b4a 100644 --- a/root/defaults/proxy.conf +++ b/root/defaults/proxy.conf @@ -15,7 +15,6 @@ proxy_send_timeout 240; # Proxy Cache and Cookie Settings proxy_cache_bypass $cookie_session; -proxy_cache_path cache/ keys_zone=auth_cache:10m; #proxy_cookie_path / "/; Secure"; # enable at your own risk, may break certain apps proxy_no_cache $cookie_session;