MCPcopy Index your code
hub / github.com/Linen-dev/linen.dev / createCertFile

Function createCertFile

packages/database/src/database.ts:41–47  ·  view source on GitHub ↗

* this function helps vercel functions to avoid download the cert since it can get it from env-vars

({ cert }: { cert?: string })

Source from the content-addressed store, hash-verified

39 * this function helps vercel functions to avoid download the cert since it can get it from env-vars
40 */
41function createCertFile({ cert }: { cert?: string }) {
42 if (!isSsl()) return;
43 if (!fs.existsSync(certOut)) {
44 createFile(cert);
45 }
46 return certOut;
47}
48
49/**
50 * this function will return the connection string for our database

Callers 1

getDatabaseUrlFunction · 0.85

Calls 2

isSslFunction · 0.85
createFileFunction · 0.85

Tested by

no test coverage detected