Add login redirect for dev environments
authorJelte Fennema-Nio <[email protected]>
Tue, 24 Sep 2024 20:27:40 +0000 (22:27 +0200)
committerMagnus Hagander <[email protected]>
Tue, 24 Sep 2024 20:27:40 +0000 (22:27 +0200)
pgcommitfest/local_settings_example.py

index 51740ff209dd1eef73cd4de3a20311494fb34d14..d3648ccbb00e846f45338c10e90e1d8aa8b74da8 100644 (file)
@@ -17,3 +17,8 @@ DATABASES = {
 # Disables the PostgreSQL.ORG authentication.
 # Use the default built-in Django authentication module.
 AUTHENTICATION_BACKENDS = ['django.contrib.auth.backends.ModelBackend']
+
+# The only login page we have in development is the Django admin login page.
+# It's not great, because it won't redirect to the page you were trying to
+# access, but it's better than a HTTP 500 error.
+PGAUTH_REDIRECT = '/admin/login/'