feat: add SESSION_SECRET_FILE and OAUTH_CLIENT_SECRET_FILE env vars
This commit is contained in:
committed by
Linus Rath
parent
9c5daa3918
commit
f9052eb23f
@@ -0,0 +1,13 @@
|
||||
import { readFileSync } from "fs";
|
||||
|
||||
export function readFileEnv(path: string | undefined): string | null {
|
||||
if (!path) {
|
||||
return null;
|
||||
}
|
||||
|
||||
try {
|
||||
return readFileSync(path, "utf-8").trim();
|
||||
} catch {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user