Update core/database.py
Browse files- core/database.py +3 -2
core/database.py
CHANGED
@@ -2,11 +2,12 @@
|
|
2 |
from sqlalchemy import create_engine
|
3 |
from sqlalchemy.ext.declarative import declarative_base
|
4 |
from sqlalchemy.orm import sessionmaker
|
|
|
5 |
|
6 |
-
|
7 |
|
8 |
engine = create_engine(
|
9 |
-
|
10 |
pool_size=5,
|
11 |
pool_pre_ping=True,
|
12 |
pool_recycle=300,
|
|
|
2 |
from sqlalchemy import create_engine
|
3 |
from sqlalchemy.ext.declarative import declarative_base
|
4 |
from sqlalchemy.orm import sessionmaker
|
5 |
+
from core.config import get_settings
|
6 |
|
7 |
+
settings = get_settings()
|
8 |
|
9 |
engine = create_engine(
|
10 |
+
settings.DATABASE_URL,
|
11 |
pool_size=5,
|
12 |
pool_pre_ping=True,
|
13 |
pool_recycle=300,
|