add jwt to config.py

This commit is contained in:
grillazz
2021-06-25 09:05:52 +02:00
parent 174a1add0b
commit 97c7a3c206
5 changed files with 35 additions and 2 deletions

View File

@@ -34,6 +34,10 @@ class Settings(BaseSettings):
asyncpg_url: str = f"postgresql+asyncpg://{pg_user}:{pg_pass}@{pg_host}:5432/{pg_database}"
asyncpg_test_url: str = f"postgresql+asyncpg://{pg_user}:{pg_pass}@{pg_host}:5432/{pg_test_database}"
jwt_secret_key: str = os.getenv("SECRET_KEY", "")
jwt_algorithm: str = os.getenv("ALGORITHM", "")
jwt_access_toke_expire_minutes: int = os.getenv("ACCESS_TOKEN_EXPIRE_MINUTES", 1)
@lru_cache()
def get_settings():