Simplify auth configs and include updates for Authelia 4.38

This commit is contained in:
Eric Nemchik
2023-04-24 19:00:52 +00:00
committed by GitHub
parent 2f740e60a8
commit 9cdedad1c8
5 changed files with 28 additions and 44 deletions
@@ -1,10 +1,10 @@
## Version 2023/04/13 - Changelog: https://github.com/linuxserver/docker-swag/commits/master/root/defaults/nginx/authelia-location.conf.sample
## Version 2023/04/24 - Changelog: https://github.com/linuxserver/docker-swag/commits/master/root/defaults/nginx/authelia-location.conf.sample
# Make sure that your authelia container is in the same user defined bridge network and is named authelia
# Rename /config/nginx/proxy-confs/authelia.subdomain.conf.sample to /config/nginx/proxy-confs/authelia.subdomain.conf
# Make sure that the authelia configuration.yml has 'path: "authelia"' defined
## Send a subrequest to Authelia to verify if the user is authenticated and has permission to access the resource.
auth_request /authelia/api/verify;
auth_request /authelia/api/authz/auth-request;
## If the subreqest returns 200 pass to the backend, if the subrequest returns 401 redirect to the portal.
error_page 401 = @authelia_proxy_signin;
@@ -23,3 +23,6 @@ proxy_set_header Remote-User $user;
## Include the Set-Cookie header if present.
auth_request_set $set_cookie $upstream_http_set_cookie;
add_header Set-Cookie $set_cookie;
## Set $redirection_url to the location header of the response from the auth request
auth_request_set $redirection_url $upstream_http_location;