Skip to content

Commit a68a308

Browse files
committed
only configure ssl in production - the previous fix broke the local connection
1 parent 6e929c7 commit a68a308

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

server/config/database.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@ module.exports = ({ env }) => ({
2929
username: env('DATABASE_USERNAME', 'postgres'),
3030
password: env('DATABASE_PASSWORD', 'postgres'),
3131
schema: 'public',
32-
ssl: { rejectUnauthorized: false }
32+
ssl: env('NODE_ENV') == 'production'
33+
? { rejectUnauthorized: false }
34+
: false
3335
},
3436
options: {
3537
'pool': {

0 commit comments

Comments
 (0)