[experimental-services] multi service builds#14617
[experimental-services] multi service builds#14617ricardo-agz wants to merge 37 commits intomainfrom
Conversation
🦋 Changeset detectedLatest commit: ac12ea1 The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
…to array of service names
…son' into ricardo/flow-5572-multi-service-builds
📦 CLI Tarball ReadyThe Vercel CLI tarball for this PR is now available! Quick TestYou can test this PR's CLI directly by running: npx https://vercel-e7b3zm17c.vercel.sh/tarballs/vercel.tgz --helpUse in vercel.jsonTo use this CLI version in your project builds, add to your {
"build": {
"env": {
"VERCEL_CLI_VERSION": "vercel@https://vercel-e7b3zm17c.vercel.sh/tarballs/vercel.tgz"
}
}
} |
🧪 Unit Test StrategyComparing: Strategy: Code changed outside of a package - running all unit tests Affected packages - 41 (100%)
Results
This comment is automatically generated based on the affected testing strategy |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
| builderUse = getBuilderForRuntime(runtime!); | ||
| builderSrc = config.entrypoint!; | ||
| } | ||
|
|
There was a problem hiding this comment.
Should we validate if builderSrc actually exists to catch config skew?
There was a problem hiding this comment.
we could but it is also handled gracefully by the builders themselves, for example in the python builder
Is the plan to use separate venv for each service? |
@elprans The case for this would be if you have two separate python services, e.g. a Flask one and a FastAPI one with separate |
| : routePrefix; | ||
| rewrites.push({ | ||
| src: `^/${normalizedPrefix}(?:/.*)?$`, | ||
| dest: routePrefix, |
There was a problem hiding this comment.
Need to figure out a way to make rewrites actually rewrite the route so that the service sees dest and not src (this is outside of this PR, but I think it's important to nail this before this lands as this is part of the contract).
Based off of #14617 except without the zero-config auto-detection Implements the logic to actually run multiple builds when `experimentalServices` is configured in `vercel.json` and the framework preset is set to "services" --------- Co-authored-by: vercel[bot] <35613825+vercel[bot]@users.noreply.github.com>
Implements the baseline zero-config services detection when a project's framework = "services"
Also implements the actual build for the multiple services, either specified in
vercel.jsonor auto-detectedFuture PR TODOs:
.vercel/pythonwhich causes issues since other services can add/remove dependencies from the virtual environment that the other services depend on