mirror of
https://github.com/grillazz/fastapi-sqlalchemy-asyncpg.git
synced 2025-08-26 16:40:40 +03:00
update project setting with new env vars
This commit is contained in:
parent
95ed21bdd5
commit
a1fbb86bab
@ -1,12 +1,16 @@
|
||||
import os
|
||||
from functools import lru_cache
|
||||
|
||||
from pydantic import PostgresDsn
|
||||
from pydantic import PostgresDsn, RedisDsn
|
||||
from pydantic_settings import BaseSettings
|
||||
|
||||
|
||||
class Settings(BaseSettings):
|
||||
asyncpg_url: PostgresDsn = os.getenv("SQL_URL")
|
||||
secret_key: str = os.getenv("FERNET_KEY")
|
||||
redis_url: RedisDsn = os.getenv("REDIS_URL")
|
||||
jwt_algorithm: str = os.getenv("JWT_ALGORITHM")
|
||||
jwt_expire: int = os.getenv("JWT_EXPIRE")
|
||||
|
||||
|
||||
@lru_cache
|
||||
|
Loading…
x
Reference in New Issue
Block a user