这是indexloc提供的服务,不要输入任何密码
Skip to content

fix: update env variables supported by nitro #10176

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 19, 2025

Conversation

pi0
Copy link
Contributor

@pi0 pi0 commented Mar 15, 2025

#9860

Deployment providers provide environmental variables to be detected.

Nitro uses this mechanism to auto-detect deployment providers when building.

I have made a handcrafted list of some common items to nuxt and nitro frameworks + SERVER_* (nitro supported env).

  • aws_amplify: AWS_APP_ID
  • azure_static: INPUT_AZURE_STATIC_WEB_APPS_API_TOKEN
  • cleavr: CLEAVR
  • cloudflare_pages: CF_PAGES
  • firebase_app_hosting: FIREBASE_APP_HOSTING
  • netlify: NETLIFY
  • stormkit: STORMKIT
  • vercel: NOW_BUILDER
  • zeabur: ZEABUR
  • cleavr: CLEAVR
  • render.com: RENDER

Important

This list will be most likely updated over time, meaning turborepo support will be broken from time to time and need to manually be updated. Nitro uses std-env as source of this list.

Note

Having list of provider envs under each framework, means that turborepo does not supports platform envs for frameworks not explicitly listed in this json (there are already few nitro based ones missing)

@pi0 pi0 requested a review from a team as a code owner March 15, 2025 13:39
@turbo-orchestrator turbo-orchestrator bot added the needs: triage New issues get this label. Remove it after triage label Mar 15, 2025
Copy link

vercel bot commented Mar 15, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
examples-basic-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-designsystem-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-gatsby-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-kitchensink-blog ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-native-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-nonmonorepo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-svelte-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-tailwind-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
examples-vite-web ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm
turbo-site ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 19, 2025 8:21pm

Copy link

vercel bot commented Mar 15, 2025

@pi0 is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

Copy link
Member

@chris-olszewski chris-olszewski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR!

This gets us to a better spot since --env-mode=loose use could lead to a cache hit from a build that inferred a different provider preset.

@chris-olszewski chris-olszewski changed the title update env variables supported by nitro fix: update env variables supported by nitro Mar 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs: triage New issues get this label. Remove it after triage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants