diff --git a/infra/.env.example b/infra/.env.example index 83a9a78..84e8d29 100644 --- a/infra/.env.example +++ b/infra/.env.example @@ -10,11 +10,11 @@ USE_SQLITE=True # Для PostgeSQL DB_ENGINE=django.db.backends.postgresql -DB_NAME= +POSTGRES_DB= POSTGRES_USER= POSTGRES_PASSWORD= -DB_HOST= -DB_PORT= +POSTGRES_HOST= +POSTGRES_PORT= # Переменные для работы с docker. DOCKERHUB_USERNAME_FRONT= diff --git a/src/backend/config/settings/base.py b/src/backend/config/settings/base.py index e1343a7..190385c 100644 --- a/src/backend/config/settings/base.py +++ b/src/backend/config/settings/base.py @@ -78,11 +78,11 @@ DATABASES = { "default": { "ENGINE": getenv("DB_ENGINE", default="django.db.backends.postgresql"), - "NAME": getenv("DB_NAME", default="db_test"), + "NAME": getenv("POSTGRES_DB", default="db_test"), "USER": getenv("POSTGRES_USER", default="admin_test"), "PASSWORD": getenv("POSTGRES_PASSWORD", default="postgre_admin"), - "HOST": getenv("DB_HOST", default="db_test"), - "PORT": getenv("DB_PORT", default=5432), + "HOST": getenv("POSTGRES_HOST", default="db_test"), + "PORT": getenv("POSTGRES_PORT", default=5432), } }