Skip to content

Commit 7989628

Browse files
committed
[db] patch ability to enable SSL for database connection
1 parent c5fac3e commit 7989628

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/common-ts/src/database/index.ts

+3-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@ export const connectDatabase = async (options: ConnectOptions): Promise<Sequeliz
2929
username,
3030
password,
3131
database,
32-
ssl: sslEnabled,
32+
dialectOptions: {
33+
ssl: sslEnabled ? { require: true, rejectUnauthorized: false } : false,
34+
},
3335
pool: {
3436
max: poolMax,
3537
min: poolMin,

0 commit comments

Comments
 (0)