As I work on deploying my Vesper server to Heroku, I've encountered a challenge with the ormconfig.json file that Vesper requires.
While setting up my local database, everything runs smoothly as I can input all the necessary fields for the connection string. However, when it comes to adding a database in Heroku, I only have access to the full URL and I'm unsure where to place it within the configuration file.
Currently, this is how my ormconfig.json looks:
{
"type": "postgres",
"host": "localhost",
"port": 5432,
"username": "postgres",
"password": "password",
"database": "test",
"synchronize": true,
"entities": ["target/entity/**/*.js"],
"migrations": ["target/migrations/*.js"],
"cli": {
"migrationsDir": "src/migrations"
}
}
I'm hoping to streamline the configuration by replacing most of the fields with just the database_url, but I haven't been able to find any documentation specifying where exactly to include it.