Proxito: serve multiple projects under one domain by path#13140
Draft
ericholscher wants to merge 1 commit into
Draft
Proxito: serve multiple projects under one domain by path#13140ericholscher wants to merge 1 commit into
ericholscher wants to merge 1 commit into
Conversation
Add a SERVE_PROJECTS_BY_PATH feature that lets a single domain serve other projects under a path prefix (e.g. example.com/docs/<project-slug>/) without modeling each one as a subproject. The unresolver matches the leading path segment to a project by slug, scoped to projects that share an owner with the domain's project so unrelated projects can't be exposed. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VPEKF2tcrc5DqDLMsdkNUz
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
A customer wants to host many projects under a single path on their own company domain (e.g.
https://example.com/docs/<project>/…) but can't point that DNS at us. Today the only way to serve several projects under one domain by path is to model them as subprojects of a parent project. That works, but it forces customers to bend their project layout into a parent/child tree they don't otherwise want, and inherits subproject limitations.This is a draft / RFC exploring the alternative: serve projects under a domain by path without a subproject relationship.
What
Adds a
SERVE_PROJECTS_BY_PATHfeature on the domain's project. When enabled, the unresolver matches the leading path segment to a project by slug (mirroring how_match_subprojectworks, but without aProjectRelationship), soexample.com/<subproject-prefix>/<project-slug>/…resolves directly.custom_subproject_prefixas the mount prefix (defaults to/projects/).feature_idhas no DB-level choices).Combine with
X-RTD-Slug(RESOLVE_PROJECT_FROM_HEADER) so the customer's reverse proxy can identify the domain's project without DNS, and with the prefix work in the base PR so/_/paths stay under the proxied path.Open questions for reviewers
custom_subproject_prefixthe right knob, or should this be a dedicated field onDomain/the project?This is stacked on #13139 (un-prefix
/_/in nginx); review that first.🤖 Draft generated by Claude Code (AI agent), for review.