express-typescript-boilerplate
express-typescript-boilerplate copied to clipboard
Error connecting to PostgreSQL with SSL
When trying to connect to a PostgreSQL the following error occurs (on yarn run setup):
error: no pg_hba.conf entry for host "HOSTNAME", user "USERNAME", database "PASSWORD", SSL off
This is due to TypeORM not having the ssl: on option (and I couldn't find an existing .env var corresponding to it).
For now, to avoid changing the code for initial setup I've been running PGSSLMODE=require to fix this issue
(full command PGSSLMODE=require yarn run setup)