Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Oct 21, 2025

Fixes #5308

This PR updates all documentation to reflect the new polyglot-friendly environment variable format for service endpoints introduced in dotnet/aspire#12141.

Changes

The environment variable naming convention for service endpoints has been updated from the .NET-specific format to a more language-agnostic format that works seamlessly with JavaScript, Python, and other non-.NET technologies.

Before

Environment variables used the format services__{resourcename}__{endpointname}__{index}:

var apiservice = builder.AddProject<Projects.ApiService>("apiservice");
var frontend = builder.AddProject<Projects.Frontend>("frontend")
    .WithReference(apiservice);

This generated environment variables like:

  • services__apiservice__http__0="http://localhost:5455"
  • services__apiservice__https__0="https://localhost:7356"

After

Environment variables now use the format {RESOURCENAME}_{ENDPOINTNAME}:

The same code now generates:

  • APISERVICE_HTTP="http://localhost:5455"
  • APISERVICE_HTTPS="https://localhost:7356"

Updated Documentation

  • fundamentals/app-host-overview.md - Updated service endpoint environment variable format explanation and examples
  • get-started/build-aspire-apps-with-nodejs.md - Updated JavaScript integration examples (Angular, React, Vue)
  • deployment/manifest-format.md - Updated manifest format examples
  • deployment/azd/aca-deployment-azd-in-depth.md - Updated Azure Container Apps deployment examples
  • fundamentals/orchestrate-resources.md - Updated external service examples
  • extensibility/dev-tunnels-integration.md - Updated dev tunnels integration examples
  • testing/snippets/ - Updated test assertions across all three test frameworks (xUnit, MSTest, NUnit)

The new format is uppercase, doesn't include an index for single endpoints, and follows a consistent pattern that makes it easier to use in polyglot scenarios where non-.NET applications need to consume Aspire services.

Original prompt

Please address #5308 - by considering the changes in dotnet/aspire#12141. Look for all places where we refer to the structure of the env var, for example services__*


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.


Internal previews

📄 File 🔗 Preview link
docs/deployment/azd/aca-deployment-azd-in-depth.md docs/deployment/azd/aca-deployment-azd-in-depth
docs/deployment/manifest-format.md docs/deployment/manifest-format
docs/extensibility/dev-tunnels-integration.md docs/extensibility/dev-tunnels-integration
docs/fundamentals/app-host-overview.md docs/fundamentals/app-host-overview
docs/fundamentals/orchestrate-resources.md docs/fundamentals/orchestrate-resources
docs/get-started/build-aspire-apps-with-nodejs.md docs/get-started/build-aspire-apps-with-nodejs

Co-authored-by: IEvangelist <7679720+IEvangelist@users.noreply.github.com>
Copilot AI changed the title [WIP] Update references to env var structure in documentation Update environment variable format to polyglot-friendly pattern Oct 21, 2025
Copilot finished work on behalf of IEvangelist October 21, 2025 12:17
Copilot AI requested a review from IEvangelist October 21, 2025 12:17
@IEvangelist IEvangelist marked this pull request as ready for review October 23, 2025 11:52
@IEvangelist IEvangelist merged commit 0fec1c7 into release-13 Oct 23, 2025
12 checks passed
@IEvangelist IEvangelist deleted the copilot/update-env-var-structure-references branch October 23, 2025 11:55
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.

2 participants