This commit is contained in:
roma-dxunvrs
2025-11-30 12:38:46 +03:00
commit 27466a255f
17 changed files with 250 additions and 0 deletions

0
app/core/__init__.py Normal file
View File

16
app/core/config.py Normal file
View File

@@ -0,0 +1,16 @@
from pathlib import Path
from pydantic import BaseModel
from pydantic_settings import BaseSettings
BASE_DIR = Path(__file__).parent.parent.parent
class AuthJWT(BaseModel):
private_key_path: Path = BASE_DIR/"certs"/"jwt-private.pem"
public_key_path: Path = BASE_DIR/"certs"/"jwt-public.pem"
algorithm: str = "RS256"
access_token_expire_minutes: int = 15
class Settings(BaseSettings):
auth_jwt: AuthJWT = AuthJWT()
settings = Settings()