mirror of
https://github.com/bellingcat/whisperbox-transcribe.git
synced 2026-06-13 05:58:35 +03:00
feat: initial project setup
This commit is contained in:
18
app/config.py
Normal file
18
app/config.py
Normal file
@@ -0,0 +1,18 @@
|
||||
import os
|
||||
|
||||
from pydantic import BaseSettings
|
||||
|
||||
|
||||
class Settings(BaseSettings):
|
||||
DATABASE_URI: str
|
||||
ENVIRONMENT: str
|
||||
|
||||
class Config:
|
||||
env_file = ".env"
|
||||
env_file_encoding = "utf-8"
|
||||
|
||||
|
||||
if "ENVIRONMENT" in os.environ and os.environ["ENVIRONMENT"] == "test":
|
||||
settings = Settings(_env_file=".env.test") # type: ignore
|
||||
else:
|
||||
settings = Settings()
|
||||
Reference in New Issue
Block a user