diff --git a/.env.dist b/.env.dist index 03d4598..f5f8f96 100644 --- a/.env.dist +++ b/.env.dist @@ -8,7 +8,7 @@ SECRET_KEY=secret ALLOWED_HOSTS=* # DATABASE -# Format: http://www.postgresql.org/docs/current/static/libpq-connect.html#LIBPQ-CONNSTRING +# Format: https://django-environ.readthedocs.io/en/latest/types.html#environ-env-db-url DATABASE_URL=postgresql://[user[:password]@][netloc][:port][/dbname][?param1=value1&...] # EMAIL @@ -19,5 +19,5 @@ SERVER_EMAIL=webmaster@example.com # CACHE CACHE_URL=rediscache://127.0.0.1:6379/1?client_class=django_redis.client.DefaultClient&password=ungithubbed-secret -# URL PREFIX -URL_PREFIX= +# FILES +MEDIA_ROOT=/path/to/media diff --git a/project_name/settings/base.py b/project_name/settings/base.py index e7a8385..e1db57e 100644 --- a/project_name/settings/base.py +++ b/project_name/settings/base.py @@ -91,15 +91,9 @@ 'django.contrib.auth.password_validation.UserAttributeSimilarityValidator' ), }, - { - 'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator', - }, - { - 'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator', - }, - { - 'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator', - }, + {'NAME': 'django.contrib.auth.password_validation.MinimumLengthValidator'}, + {'NAME': 'django.contrib.auth.password_validation.CommonPasswordValidator'}, + {'NAME': 'django.contrib.auth.password_validation.NumericPasswordValidator'}, ] AUTH_USER_MODEL = 'account.User' @@ -128,7 +122,7 @@ MEDIA_URL = '/media/' -MEDIA_ROOT = BASE_DIR / 'resources/media' +MEDIA_ROOT = env('MEDIA_ROOT') # Default primary key field type