mirror of
https://gitlab.com/MoonTestUse1/AdministrationItDepartmens.git
synced 2025-08-14 00:25:46 +02:00
add websockets suppor97
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
"""Application configuration"""
|
||||
from pydantic_settings import BaseSettings
|
||||
from typing import Optional
|
||||
from pydantic import ConfigDict
|
||||
|
||||
|
||||
class Settings(BaseSettings):
|
||||
@@ -32,9 +33,11 @@ class Settings(BaseSettings):
|
||||
if not self.DATABASE_URL:
|
||||
self.DATABASE_URL = f"postgresql://{self.POSTGRES_USER}:{self.POSTGRES_PASSWORD}@{self.POSTGRES_HOST}:{self.POSTGRES_PORT}/{self.POSTGRES_DB}"
|
||||
|
||||
class Config:
|
||||
"""Pydantic config"""
|
||||
env_file = ".env"
|
||||
model_config = ConfigDict(
|
||||
env_file=".env",
|
||||
extra="allow", # Разрешаем дополнительные поля
|
||||
case_sensitive=True # Учитываем регистр
|
||||
)
|
||||
|
||||
|
||||
settings = Settings()
|
Reference in New Issue
Block a user