Last active
July 17, 2020 08:51
-
-
Save mmichealjroberts/88cb192f863121ad2349b6e781912193 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
db = {} | |
db['ENGINE'] = 'django.db.backends.postgresql' | |
db['OPTIONS'] = {'autocommit': True} | |
db['NAME'] = my_model_db['database'] | |
db['PASSWORD'] = my_model_db['password'] | |
db['USER'] = my_model_db['user'] | |
db['HOST'] = my_model_db['host'] | |
logger.info("Connecting to database {db} on {host}".format(db=source_db['NAME'], host=source_db['HOST'])) | |
connections.databases['dynamic_database_1'] = db |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment