mattam
mattam
CDCloudflare Developers
Created by mattam on 9/2/2024 in #pages-help
Dashboard environment variables not available on process.env at build time
I'm trying to deploy a tincms project to cloudflare pages. I've added these env vars in the dashboard for the project. The build-time config for tina tries to read them off process.env:
console.log('Process.env:', process.env);
console.log('Tina Client ID:', process.env.NEXT_PUBLIC_TINA_CLIENT_ID);
console.log('Tina Token:', process.env.TINA_TOKEN);
console.log('Process.env:', process.env);
console.log('Tina Client ID:', process.env.NEXT_PUBLIC_TINA_CLIENT_ID);
console.log('Tina Token:', process.env.TINA_TOKEN);
But they're undefined, breaking the build. What am I missing?
6 replies