-
Notifications
You must be signed in to change notification settings - Fork 450
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
feat(cli): add deploy command for non-studio applications #8592
base: feat/org-select-for-core-apps
Are you sure you want to change the base?
feat(cli): add deploy command for non-studio applications #8592
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
2 Skipped Deployments
|
e441d77
to
e4f839f
Compare
No changes to documentation |
⚡️ Editor Performance ReportUpdated Fri, 14 Feb 2025 15:56:27 GMT
Detailed information🏠 Reference resultThe performance result of
🧪 Experiment resultThe performance result of this branch
📚 Glossary
|
Component Testing Report Updated Feb 14, 2025 3:59 PM (UTC) ❌ Failed Tests (2) -- expand for details
|
e4f839f
to
8aaae08
Compare
8aaae08
to
97e7988
Compare
97e7988
to
596ed96
Compare
596ed96
to
bee4196
Compare
bee4196
to
2c7d7e8
Compare
Coverage Report
File CoverageNo changed files found. |
04c61aa
to
4672654
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly nitpick comments but looks great otherwise. Tested it and was able to get an app deployed 🚀
packages/sanity/src/_internal/cli/commands/app/deployCommand.ts
Outdated
Show resolved
Hide resolved
4672654
to
6a0678b
Compare
6a0678b
to
75aa903
Compare
75aa903
to
5737dbd
Compare
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Description
This PR builds on #8394 by adding a command to deploy non-studio apps. Non-studio apps will not have the same URL assumptions as deployed studios, so the intent of creating a core app is as follows:
sanity
detects if you are in a non-studio application by readingsanity.cli.ts
, specifically looking for the__experimental_coreAppConfiguration
key.appId
already present, generate one and ask the user to title it.${appHost}.sanity.studio
but this is obscured).The flow is very similar to that of deploying a studio, but some language and options have changed.
What to review
This PR assumes that the
organizationId
(needed for deployment) is in theapi
key of sanity.cli, as in #8573 . This doesn't have to be the case, and please do let me know if we'd like to change it.appHost
may not make total sense to our users, and I'm happy to change that key in configuration as well.If any other language is odd, please let me know. If the user flow doesn't feel right, please let me know.
Testing
Tests were added for existing test files. If you'd also like to manually test, please do the following:
pnpx sanity@latest init --template core-app
sanity
dependency to3.74.2-canary.98+555ec258f0
in your package.json and installto the generated sanity.cli file.
4. Set your environment to staging with
export SANITY_INTERNAL_ENV=staging
5. Run
sanity app deploy
and examine the instructions and flow. Feel free to also put the generated appHost in yoursanity.cli
file under__experimental_coreAppConfiguration
. You can run it again with the configuration. To see your application, you can check Brett in staging to find your app and go to its designated appHost.Notes for release
None, internal.