I can't connect to the admin site in production #5077
-
Hi all. I have a site created using cookiecutter-django w/Docker, webpack, DRF, whitenoise, celery & sentry. I can access the website in production without any problem. Both the website and the admin work great locally. The problem is when I try to access the admin site in production. When I try to access it I get the main site, but the page title changes to "Page not found". |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Did you set a specific value for the admin URL? By default it's a random value set by an environment variable: |
Beta Was this translation helpful? Give feedback.
-
I can't believe I didn't read production.py on this one. It never occurred to me adding a second layer of security by having a secret admin url. Now that I know about it, I agree it makes sense. Thanks! |
Beta Was this translation helpful? Give feedback.
Did you set a specific value for the admin URL? By default it's a random value set by an environment variable:
https://github.com/cookiecutter/cookiecutter-django/blob/master/%7B%7Bcookiecutter.project_slug%7D%7D%2Fconfig%2Fsettings%2Fproduction.py#L228-L231