diff --git a/pyproject.toml b/pyproject.toml index 0905890f..9b5f4b4a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -10,7 +10,7 @@ readme = "README.md" python = "^3.12" SQLAlchemy = "^2.0.22" httpx = "^0.25.0" -psycopg2 = "^2.9.9" +psycopg2-binary = "^2.9.9" redis = {extras = ["hiredis"], version = "^5.0.1"} uvicorn = "^0.24" sentry-sdk = "^1.32.0" diff --git a/settings.py b/settings.py index edaaa36e..fe168802 100644 --- a/settings.py +++ b/settings.py @@ -2,8 +2,8 @@ from os import environ PORT = 8080 DB_URL = ( - environ.get("DATABASE_URL") - or environ.get("DB_URL") + environ.get("DATABASE_URL", "").replace("postgres://", "postgresql://") + or environ.get("DB_URL", "").replace("postgres://", "postgresql://") or "postgresql://postgres@localhost:5432/discoursio" ) REDIS_URL = environ.get("REDIS_URL") or "redis://127.0.0.1"