You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
31 lines
699 B
31 lines
699 B
"""
|
|
Application Configuration
|
|
|
|
@author: {{ author }}
|
|
@date: {{ date }}
|
|
"""
|
|
import os
|
|
from pydantic_settings import BaseSettings
|
|
|
|
class Settings(BaseSettings):
|
|
"""Application Settings"""
|
|
APP_NAME: str = "{{ project_name }}"
|
|
APP_VERSION: str = "1.0.0"
|
|
DEBUG: bool = True
|
|
|
|
# Database
|
|
DATABASE_URL: str = "{{ database_url | default('sqlite:///./sql_app.db') }}"
|
|
|
|
# JWT
|
|
SECRET_KEY: str = "{{ secret_key | default('your-secret-key-change-in-production') }}"
|
|
ALGORITHM: str = "HS256"
|
|
ACCESS_TOKEN_EXPIRE_MINUTES: int = 30
|
|
|
|
# CORS
|
|
ALLOWED_ORIGINS: list = ["*"]
|
|
|
|
class Config:
|
|
env_file = ".env"
|
|
case_sensitive = True
|
|
|
|
settings = Settings()
|
|
|