chore(build): fix db ssl for DO
authorxangelo <me@xangelo.ca>
Wed, 4 Dec 2024 20:00:13 +0000 (15:00 -0500)
committerxangelo <me@xangelo.ca>
Wed, 4 Dec 2024 20:00:13 +0000 (15:00 -0500)
knexfile.ts
src/server/lib/db.ts

index 987738cb5a779eca7fbc95854d9c757356f9e22c..ea4b0b7ce4049c8370f5a44c45947baccf7ad2c8 100644 (file)
@@ -11,7 +11,8 @@ const config: { [key: string]: Knex.Config } = {
     connection: {
       connectionString: connectionUrl,
       ssl: {
-        rejectUnauthorized: false
+        rejectUnauthorized: false,
+        ca: process.env.CA_CERT
       }
     },
     pool: {
@@ -28,7 +29,8 @@ const config: { [key: string]: Knex.Config } = {
     connection: {
       connectionString: connectionUrl,
       ssl: {
-        rejectUnauthorized: false
+        rejectUnauthorized: false,
+        ca: process.env.CA_CERT
       }
     },
     pool: {
index 7b9fe4abb28f7a07e9b60f1dfb0c93d3859e68d8..6a19281d3941cda3010d3bb96495400b766ff15f 100644 (file)
@@ -10,7 +10,8 @@ export const db = knex({
   connection: {
     connectionString: connectionUrl,
     ssl: {
-      rejectUnauthorized: false
+      rejectUnauthorized: false,
+      ca: process.env.CA_CERT
     }
   }
 });