|
1 | 1 | """ |
2 | 2 | Django settings for gettingstarted project. |
3 | 3 |
|
4 | | -Generated by 'django-admin startproject' using Django 5.0. |
| 4 | +Generated by 'django-admin startproject' using Django 5.1. |
5 | 5 |
|
6 | 6 | For more information on this file, see |
7 | | -https://docs.djangoproject.com/en/5.0/topics/settings/ |
| 7 | +https://docs.djangoproject.com/en/5.1/topics/settings/ |
8 | 8 |
|
9 | 9 | For the full list of settings and their values, see |
10 | | -https://docs.djangoproject.com/en/5.0/ref/settings/ |
| 10 | +https://docs.djangoproject.com/en/5.1/ref/settings/ |
11 | 11 | """ |
12 | 12 |
|
13 | 13 | import os |
|
21 | 21 |
|
22 | 22 |
|
23 | 23 | # Before using your Heroku app in production, make sure to review Django's deployment checklist: |
24 | | -# See https://docs.djangoproject.com/en/5.0/howto/deployment/checklist/ |
| 24 | +# See https://docs.djangoproject.com/en/5.1/howto/deployment/checklist/ |
25 | 25 |
|
26 | 26 | # Django requires a unique secret key for each Django app, that is used by several of its |
27 | 27 | # security features. To simplify initial setup (without hardcoding the secret in the source |
28 | 28 | # code) we set this to a random value every time the app starts. However, this will mean many |
29 | 29 | # Django features break whenever an app restarts (for example, sessions will be logged out). |
30 | 30 | # In your production Heroku apps you should set the `DJANGO_SECRET_KEY` config var explicitly. |
31 | 31 | # Make sure to use a long unique value, like you would for a password. See: |
32 | | -# https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-SECRET_KEY |
| 32 | +# https://docs.djangoproject.com/en/5.1/ref/settings/#std-setting-SECRET_KEY |
33 | 33 | # https://devcenter.heroku.com/articles/config-vars |
34 | 34 | # SECURITY WARNING: keep the secret key used in production secret! |
35 | 35 | SECRET_KEY = os.environ.get( |
|
49 | 49 | # On Heroku, it's safe to use a wildcard for `ALLOWED_HOSTS``, since the Heroku router performs |
50 | 50 | # validation of the Host header in the incoming HTTP request. On other platforms you may need to |
51 | 51 | # list the expected hostnames explicitly in production to prevent HTTP Host header attacks. See: |
52 | | -# https://docs.djangoproject.com/en/5.0/ref/settings/#std-setting-ALLOWED_HOSTS |
| 52 | +# https://docs.djangoproject.com/en/5.1/ref/settings/#std-setting-ALLOWED_HOSTS |
53 | 53 | if IS_HEROKU_APP: |
54 | 54 | ALLOWED_HOSTS = ["*"] |
55 | 55 | else: |
|
62 | 62 | # Use WhiteNoise's runserver implementation instead of the Django default, for dev-prod parity. |
63 | 63 | "whitenoise.runserver_nostatic", |
64 | 64 | # Uncomment this and the entry in `urls.py` if you wish to use the Django admin feature: |
65 | | - # https://docs.djangoproject.com/en/5.0/ref/contrib/admin/ |
| 65 | + # https://docs.djangoproject.com/en/5.1/ref/contrib/admin/ |
66 | 66 | # "django.contrib.admin", |
67 | 67 | "django.contrib.auth", |
68 | 68 | "django.contrib.contenttypes", |
|
109 | 109 |
|
110 | 110 |
|
111 | 111 | # Database |
112 | | -# https://docs.djangoproject.com/en/5.0/ref/settings/#databases |
| 112 | +# https://docs.djangoproject.com/en/5.1/ref/settings/#databases |
113 | 113 |
|
114 | 114 | if IS_HEROKU_APP: |
115 | 115 | # In production on Heroku the database configuration is derived from the `DATABASE_URL` |
|
137 | 137 |
|
138 | 138 |
|
139 | 139 | # Password validation |
140 | | -# https://docs.djangoproject.com/en/5.0/ref/settings/#auth-password-validators |
| 140 | +# https://docs.djangoproject.com/en/5.1/ref/settings/#auth-password-validators |
141 | 141 |
|
142 | 142 | AUTH_PASSWORD_VALIDATORS = [ |
143 | 143 | { |
|
156 | 156 |
|
157 | 157 |
|
158 | 158 | # Internationalization |
159 | | -# https://docs.djangoproject.com/en/5.0/topics/i18n/ |
| 159 | +# https://docs.djangoproject.com/en/5.1/topics/i18n/ |
160 | 160 |
|
161 | 161 | LANGUAGE_CODE = "en-us" |
162 | 162 |
|
|
168 | 168 |
|
169 | 169 |
|
170 | 170 | # Static files (CSS, JavaScript, Images) |
171 | | -# https://docs.djangoproject.com/en/5.0/howto/static-files/ |
| 171 | +# https://docs.djangoproject.com/en/5.1/howto/static-files/ |
172 | 172 |
|
173 | 173 | STATIC_ROOT = BASE_DIR / "staticfiles" |
174 | 174 | STATIC_URL = "static/" |
|
187 | 187 |
|
188 | 188 |
|
189 | 189 | # Default primary key field type |
190 | | -# https://docs.djangoproject.com/en/5.0/ref/settings/#default-auto-field |
| 190 | +# https://docs.djangoproject.com/en/5.1/ref/settings/#default-auto-field |
191 | 191 |
|
192 | 192 | DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField" |
0 commit comments