Repository navigation
[docs] Note *.dev.localhost support for polyglot AppHosts in aspire new docs - #1120
Closed
aspire-repo-bot[bot] wants to merge 1 commit into
Closed
aspire-repo-bot[bot] wants to merge 1 commit into
aspire-repo-bot[bot] wants to merge 1 commit into
Conversation
Documents the fix from microsoft/aspire#17639 where aspire run now correctly accepts *.localhost subdomains (per RFC 6761) as local resource service endpoints, enabling polyglot AppHosts scaffolded with *.dev.localhost URLs to run without error. Co-authored-by: Copilot <[email protected]>
5 of 14 tasks
David Pine (IEvangelist)
marked this pull request as ready for review
May 29, 2026 05:40
David Pine (IEvangelist)
requested a review
from Mitch Denny (mitchdenny)
as a code owner
May 29, 2026 05:40
Contributor
There was a problem hiding this comment.
Pull request overview
This docs-only PR updates the aspire new command reference to explain how *.dev.localhost URLs interact with polyglot AppHosts and the related loopback validation fix.
Changes:
- Adds a subsection for polyglot AppHosts using
*.dev.localhostURLs. - Documents the prior
ASPIRE_RESOURCE_SERVICE_ENDPOINT_URLloopback error and advises upgrading to Aspire 13.5+.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
||
| #### Polyglot AppHosts and \*.dev.localhost URLs | ||
|
|
||
| When you scaffold a polyglot AppHost (for example, a TypeScript AppHost using the Express/React template) and choose **Yes**, the `ASPIRE_RESOURCE_SERVICE_ENDPOINT_URL` in `aspire.config.json` is set to a `*.dev.localhost` subdomain (for example, `https://myappname.dev.localhost`). The Aspire runtime recognizes `*.localhost` subdomains as local endpoints — per [RFC 6761](https://www.rfc-editor.org/rfc/rfc6761) — and routes the resource service connection through `ListenLocalhost`, so no extra network access is opened. |
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.
Documents changes from microsoft/aspire#17639 —
@danegstaTargeting
release/13.4— the latest release branch onmicrosoft/aspire.dev— becauserelease/13.5(from the source PR milestone13.5) does not exist there.Why this PR is needed
PR microsoft/aspire#17639 fixed a bug where
aspire runfailed for polyglot AppHosts (for example, TypeScript AppHosts using the Express/React template) that were scaffolded with*.dev.localhostURLs. The error was:This happened because the resource service endpoint validation only checked
Uri.IsLoopback, which does not recognize RFC 6761*.localhostsubdomains. The fix extends the check to accept*.localhostsubdomains as local endpoints.The existing
aspire newdocs described the*.dev.localhostoption but did not document how it interacts with polyglot AppHosts, and did not mention the previous failure mode or the fix.Summary of changes
Updated
src/frontend/src/content/docs/reference/cli/commands/aspire-new.mdxto add a "Polyglot AppHosts and *.dev.localhost URLs" subsection under the "Yes — use *.dev.localhost URLs" heading. The new section:*.dev.localhostURLs work correctly withaspire run.*.localhostsubdomains as local per RFC 6761, routing throughListenLocalhostwithout opening new network listeners.Files modified
src/frontend/src/content/docs/reference/cli/commands/aspire-new.mdx— updated (existing page)