Getting 403 Forbidden error when specified Custom Error Page in OAuth2 Proxy

66 Views Asked by At

I am having an OAuth2-Proxy instance in which I define both error.html and sign_in.html pages as templates. Then I specified the templates directory too like this:

- --custom-templates-dir=/var/oauth2-proxy/templates

And I am getting 403 Forbidden Error from nginx, instead of a redirect to my custom error.html page. Why is this happening. How can I make sure when we do not have access or if there is an error, redirect to this error.html page?

I tried checking if the provided templates path is correct or if there is a typo, which there isn't. I am looking to having an error.html page open everytime when there is an error.

0

There are 0 best solutions below