2022-09-02 10:23:33 +00:00
|
|
|
from os import environ
|
2023-12-24 14:25:57 +00:00
|
|
|
import sys
|
2022-09-02 10:23:33 +00:00
|
|
|
|
|
|
|
PORT = 8080
|
2022-09-03 10:50:14 +00:00
|
|
|
DB_URL = (
|
2023-11-22 18:06:45 +00:00
|
|
|
environ.get("DATABASE_URL", "").replace("postgres://", "postgresql://")
|
|
|
|
or environ.get("DB_URL", "").replace("postgres://", "postgresql://")
|
2023-10-23 14:47:11 +00:00
|
|
|
or "postgresql://postgres@localhost:5432/discoursio"
|
2022-09-03 10:50:14 +00:00
|
|
|
)
|
2022-09-02 10:23:33 +00:00
|
|
|
REDIS_URL = environ.get("REDIS_URL") or "redis://127.0.0.1"
|
2023-10-23 14:47:11 +00:00
|
|
|
API_BASE = environ.get("API_BASE") or ""
|
|
|
|
AUTH_URL = environ.get("AUTH_URL") or ""
|
2022-12-04 14:03:55 +00:00
|
|
|
SENTRY_DSN = environ.get("SENTRY_DSN")
|
2023-10-23 14:47:11 +00:00
|
|
|
DEV_SERVER_PID_FILE_NAME = "dev-server.pid"
|
2023-12-24 14:25:57 +00:00
|
|
|
MODE = "development" if "dev" in sys.argv else "production"
|