CDCgov / prime-devops

Apache License 2.0
4 stars 2 forks source link

DRY up database connection config in Key Vault #40

Open jdorothy opened 3 years ago

jdorothy commented 3 years ago

We have a lot of DB config in Key Vault, and a lot of it seems duplicative. We probably don't need to store separate variables for the username, password, and the connection string which also contains the username and password, for instance. We also have keys for the DB connection string and the Metabase connection string, which pre-no-PHI user should have been the same value. This could be done a number of ways, but one thought: have the postgres_db module generate the connection string and either set that value in the Key Vault or just make it a module output.

Note: whichever approach we choose, we need at least two string-setting resources (one for the standard user, one for the no-PHI user)