Skip to content

[experimental-services] multi service builds#14617

Closed
ricardo-agz wants to merge 37 commits intomainfrom
ricardo/flow-5572-multi-service-builds
Closed

[experimental-services] multi service builds#14617
ricardo-agz wants to merge 37 commits intomainfrom
ricardo/flow-5572-multi-service-builds

Conversation

@ricardo-agz
Copy link
Copy Markdown
Contributor

@ricardo-agz ricardo-agz commented Jan 14, 2026

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.json or auto-detected

Future PR TODOs:

  • Integrate with Python's new entrypoint detection
  • Fix an issue where separate python services use the same virtual environment in .vercel/python which causes issues since other services can add/remove dependencies from the virtual environment that the other services depend on
  • Fix an issue where services 404 unless you hard code the paths to include the routePrefix

@changeset-bot
Copy link
Copy Markdown

changeset-bot bot commented Jan 14, 2026

🦋 Changeset detected

Latest commit: ac12ea1

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
vercel Patch
@vercel/fs-detectors Patch

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

@ricardo-agz ricardo-agz changed the title Ricardo/flow 5572 multi service builds DRAFT - multi service builds Jan 14, 2026
…son' into ricardo/flow-5572-multi-service-builds
Copy link
Copy Markdown
Contributor

@vercel vercel bot left a comment

Choose a reason for hiding this comment

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

🔧 Build Fix:

TypeScript compilation errors in @vercel/fs-detectors package - the explicitServices property doesn't exist in the DetectServicesOptions type, and there are related type mismatches with missing exports like getServicesBuilders and DetectedManifest.

Fix on Vercel

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Jan 15, 2026

📦 CLI Tarball Ready

The Vercel CLI tarball for this PR is now available!

Quick Test

You can test this PR's CLI directly by running:

npx https://vercel-e7b3zm17c.vercel.sh/tarballs/vercel.tgz --help

Use in vercel.json

To use this CLI version in your project builds, add to your vercel.json:

{
  "build": {
    "env": {
      "VERCEL_CLI_VERSION": "vercel@https://vercel-e7b3zm17c.vercel.sh/tarballs/vercel.tgz"
    }
  }
}

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Jan 15, 2026

🧪 Unit Test Strategy

Comparing: 7719d28ac12ea1 (view diff)

Strategy: Code changed outside of a package - running all unit tests

⚠️ All unit tests will run because global code changes could impact all packages.

Affected packages - 41 (100%)
  1. @vercel-internals/get-package-json
  2. @vercel/backends
  3. @vercel/build-utils
  4. @vercel/cervel
  5. @vercel/cli-auth
  6. @vercel/client
  7. @vercel/config
  8. @vercel/detect-agent
  9. @vercel/edge
  10. @vercel/elysia
  11. @vercel/error-utils
  12. @vercel/express
  13. @vercel/fastify
  14. @vercel/firewall
  15. @vercel/frameworks
  16. @vercel/fs-detectors
  17. @vercel/functions
  18. @vercel/gatsby-plugin-vercel-builder
  19. @vercel/go
  20. @vercel/h3
  21. @vercel/hono
  22. @vercel/hydrogen
  23. @vercel/introspection
  24. @vercel/koa
  25. @vercel/nestjs
  26. @vercel/next
  27. @vercel/node
  28. @vercel/oidc
  29. @vercel/oidc-aws-credentials-provider
  30. @vercel/python
  31. @vercel/python-analysis
  32. @vercel/redwood
  33. @vercel/related-projects
  34. @vercel/remix-builder
  35. @vercel/routing-utils
  36. @vercel/ruby
  37. @vercel/rust
  38. @vercel/static-build
  39. @vercel/static-config
  40. examples
  41. vercel

Results

  • Unit tests: All affected packages will run unit tests
  • E2E tests: Handled separately (Version Packages PRs or run-e2e-tests label)
  • Type checks: All affected packages will run type checks

This comment is automatically generated based on the affected testing strategy

@ricardo-agz ricardo-agz changed the title DRAFT - multi service builds [experimental-services] multi service builds Jan 15, 2026
@ricardo-agz ricardo-agz marked this pull request as ready for review January 15, 2026 02:13
@vercel
Copy link
Copy Markdown
Contributor

vercel bot commented Jan 21, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
koa-example Error Error Jan 21, 2026 8:23pm

Request Review

builderUse = getBuilderForRuntime(runtime!);
builderSrc = config.entrypoint!;
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Should we validate if builderSrc actually exists to catch config skew?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

we could but it is also handled gracefully by the builders themselves, for example in the python builder

@elprans
Copy link
Copy Markdown
Contributor

elprans commented Jan 22, 2026

* Fix an issue where separate python services use the same virtual environment in `.vercel/python` which causes issues since other services can add/remove dependencies from the virtual environment that the other services depend on

Is the plan to use separate venv for each service?

@ricardo-agz
Copy link
Copy Markdown
Contributor Author

ricardo-agz commented Jan 22, 2026

* Fix an issue where separate python services use the same virtual environment in `.vercel/python` which causes issues since other services can add/remove dependencies from the virtual environment that the other services depend on

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 pyproject.tomls and separate dependencies they could each be isolated

@ricardo-agz ricardo-agz requested a review from elprans January 22, 2026 05:26
: routePrefix;
rewrites.push({
src: `^/${normalizedPrefix}(?:/.*)?$`,
dest: routePrefix,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

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).

@ricardo-agz ricardo-agz marked this pull request as draft January 27, 2026 01:10
ricardo-agz added a commit that referenced this pull request Jan 28, 2026
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>
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.

3 participants