mirror of
https://github.com/stijndcl/didier.git
synced 2026-04-07 23:55:46 +02:00
Modify config files to support Mongo
This commit is contained in:
parent
b54aed24e8
commit
665d677941
6 changed files with 83 additions and 34 deletions
|
|
@ -6,16 +6,16 @@ from sqlalchemy.orm import sessionmaker
|
|||
|
||||
import settings
|
||||
|
||||
encoded_password = quote_plus(settings.DB_PASSWORD)
|
||||
encoded_password = quote_plus(settings.POSTGRES_PASS)
|
||||
|
||||
engine = create_async_engine(
|
||||
URL.create(
|
||||
drivername="postgresql+asyncpg",
|
||||
username=settings.DB_USERNAME,
|
||||
username=settings.POSTGRES_USER,
|
||||
password=encoded_password,
|
||||
host=settings.DB_HOST,
|
||||
port=settings.DB_PORT,
|
||||
database=settings.DB_NAME,
|
||||
host=settings.POSTGRES_HOST,
|
||||
port=settings.POSTGRES_PORT,
|
||||
database=settings.POSTGRES_DB,
|
||||
),
|
||||
pool_pre_ping=True,
|
||||
future=True,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue