authelia - choose portal or auth basic mode
This commit is contained in:
@@ -21,7 +21,6 @@ proxy_set_header Remote-User $user;
|
||||
proxy_set_header Remote-Groups $groups;
|
||||
proxy_set_header Remote-Name $name;
|
||||
proxy_set_header Remote-Email $email;
|
||||
# If Authelia returns 401, then nginx redirects the user to the login portal.
|
||||
# If it returns 200, then the request pass through to the backend.
|
||||
# For other type of errors, nginx will handle them as usual.
|
||||
{% if AUTHELIA_MODE == "portal" %}
|
||||
error_page 401 =302 {{ AUTHELIA_BACKEND }}/?rd=$target_url;
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user