18 lines
411 B
Python
18 lines
411 B
Python
from pydantic_settings import BaseSettings
|
|
from pathlib import Path
|
|
|
|
|
|
class Settings(BaseSettings):
|
|
PROJECT_NAME: str = "Todo API"
|
|
PROJECT_VERSION: str = "1.0.0"
|
|
|
|
# Database settings
|
|
DB_DIR: Path = Path("/app/storage/db")
|
|
SQLALCHEMY_DATABASE_URL: str = f"sqlite:///{DB_DIR}/db.sqlite"
|
|
|
|
class Config:
|
|
env_file = ".env"
|
|
case_sensitive = True
|
|
|
|
|
|
settings = Settings() |