Skip to content

Commit

Permalink
set rejectUnauthorized to false
Browse files Browse the repository at this point in the history
  • Loading branch information
KatyH820 committed Apr 30, 2024
1 parent e45f40c commit 224be15
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions apps/server/src/functions/cron/getWeeklyHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ const isProduction = process.env.NODE_ENV === "production";
const connectionString = env.DATABASE_URL;
const sslConfig = isProduction
? {
rejectUnauthorized: false,
ca: fs.readFileSync(
path.join(__dirname, "../../../../../certs", "global-bundle.pem"),
),
Expand Down
7 changes: 6 additions & 1 deletion apps/server/src/functions/cron/updateDailyHandler.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,17 @@ const isProduction = process.env.NODE_ENV === "production";
const connectionString = env.DATABASE_URL;
const sslConfig = isProduction
? {
rejectUnauthorized: false,
ca: fs.readFileSync(
path.join(__dirname, "../../../../../certs", "global-bundle.pem"),
),
}
: null;

console.log(
fs.readFileSync(
path.join(__dirname, "../../../../../certs", "global-bundle.pem"),
),
);
export const main = async (_event, _context) => {
try {
const db = createDrizzle({
Expand Down

0 comments on commit 224be15

Please sign in to comment.