Skip to content

Commit

Permalink
[db] patch ability to enable SSL for database connection
Browse files Browse the repository at this point in the history
  • Loading branch information
wesley-u410 committed Nov 18, 2024
1 parent c5fac3e commit ac13a2a
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion packages/common-ts/src/database/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,11 @@ export const connectDatabase = async (options: ConnectOptions): Promise<Sequeliz
username,
password,
database,
ssl: sslEnabled,
...(sslEnabled && {
dialectOptions: {
ssl: { require: true, rejectUnauthorized: true },
},
}),
pool: {
max: poolMax,
min: poolMin,
Expand Down

0 comments on commit ac13a2a

Please sign in to comment.