Skip to content

Instantly share code, notes, and snippets.

def construct_db_url(config):
DSN = "postgresql://{user}:{password}@{host}:{port}/{database}"
return DSN.format(
user=config['DB_USER'],
password=config['DB_PASS'],
database=config['DB_NAME'],
host=config['DB_HOST'],
port=config['DB_PORT'],
)
@Yodo92
Yodo92 / Test
Created September 14, 2017 05:03
0x435510aA5405289061Bf9F42b8625728c3039afA