env variables not available on api/.../route.ts #70947
Unanswered
lucifer-simplai
asked this question in
App Router
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I have an application using next version 14.1.0 which uses app router now I have an api routes src/app/api/env/route.ts which is as below
now the issue is I am not getting env variables in this route even though they are present in the pod env
when running printenv command in pod I can see the variables.
I am not able to see the logs of this route in server logs as well as even thought the route is executed and the response was received and the response is empty object what can be the issue
Also let me know if extra config is need for this to be enabled from code level or devops end while configuring pod
FYI these are runtime env variables and not buildtime. I hope this will not be an issue
Beta Was this translation helpful? Give feedback.
All reactions