-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Added custom 404 and 500 templates #415
Conversation
In production, you would set those pages in the load balancer configuration file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some comments
Hmm ok, so does this need any changing here? What would be the instructions to implement this? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
So no extra instructions are needed in the README in order to set these up or anything? @srggrs |
I'll test how it works and add them directly to the main documentation I'm building |
I've added custom 404 and 500 templates, which I believe are read by default as long as they are named and placed in the templates as I've done. So I think this should just work once in production.
I managed to test it on my
debug=True
environment by using this technique: https://spapas.github.io/2015/04/29/django-show-404-page/.I used the 404.html template from sb-admin-2.
Preview of the 500 page:
![Screen Shot 2020-11-17 at 11 28 20](https://user-images.githubusercontent.com/3306161/99324449-618af900-28c8-11eb-81c5-5f9a5b18ff10.png)
Fixes #290.