Derek Stegelman

Django Downtime

Recently I've had a need to display a down page, or simply redirect users to a different site while I did maintenance. I couldn't quite find what I was looking for so built my own downtime app. While its not perfect it allows me to put up a down page, or just redirect users to another site while I do database maintenance. I've published the code on Github and the package is available on PyPi as well. pip install django-downtime add to installed apps downtime Add downtime middleware to the top your list of installed middlewares 'downtime.middleware.DowntimeMiddleware', Settings ``` DOWNTIMEEXEMPTPATHS = ( '/admin', '/otherlocationnot_down', )

DOWNTIMEURLREDIRECT = "http://errors.mypage.com" ``` You can check out the rest of the documentation on Github or Read the Docs