Skip to content
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

Fix/add env prefix exceptions #4554

Closed

Conversation

arjanmalda
Copy link

@arjanmalda arjanmalda commented Jun 2, 2023

Description

  • I have added an array with env keys that should not be prefixed with the default prefix 'SANITY_STUDIO_'.

  • This has been done because prefixed envs can cause unexpected behaviour in some cases.

  • For example the default envs from Vercel could previously only be used in the studio, when manually prefixing them with SANITY_STUDIO_.

  • The tests are failing on Vercel but locally the tests pass and I can build the project. @ reviewer, can you see what is going on in the Vercel test studio?

Steps to review

Please check and (if needed) elaborate on the envsExceptedFromPrefix array added in file getStudioEnvironmentVariables.

Steps to test

  • Deploy the studio on Vercel, and see if you can use VERCEL_ENV in stead of SANITY_STUDIO_VERCEL_ENV.

Notes for release

  • List of envs that should not be prefixed with 'SANITY_STUDIO_' added

@vercel
Copy link

vercel bot commented Jun 2, 2023

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

Name Status Preview Comments Updated (UTC)
performance-studio ✅ Ready (Inspect) Visit Preview Jun 2, 2023 11:19am
1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
studio-workshop ⬜️ Ignored (Inspect) Jun 2, 2023 11:19am

@vercel
Copy link

vercel bot commented Jun 2, 2023

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

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant