chore(debug): envs in api functions

This commit is contained in:
Michael Zetterberg
2024-05-17 15:26:25 +02:00
parent 62a8374144
commit f782ae796e
2 changed files with 9 additions and 2 deletions

View File

@@ -32,6 +32,13 @@ if (!NEXTAUTH_URL) {
}
let contents = fs.readFileSync("./.env", { encoding: "utf-8" })
console.log({ pre_contents: contents })
console.log({
SCANDIC_ENV_URL,
NEXTAUTH_URL,
DEPLOY_PRIME_URL,
URL,
})
contents = contents.replace(
// 'URL="REPLACEME-ON-BUILD-ON-NETLIFY"',
@@ -45,4 +52,6 @@ contents = contents.replace(
`NEXTAUTH_URL="${NEXTAUTH_URL}"`
)
console.log({ post_contents: contents })
fs.writeFileSync("./.env", contents, { encoding: "utf-8" })