Skip to content

AddAzureContainerAppEnvironment should use the environment name as a prefix - #8606

Merged
David Fowler (davidfowl) merged 4 commits into
microsoft:mainfrom
eerhardt:FixAcaEnvironmentNaming
Apr 8, 2025
Merged

AddAzureContainerAppEnvironment should use the environment name as a prefix#8606
David Fowler (davidfowl) merged 4 commits into
microsoft:mainfrom
eerhardt:FixAcaEnvironmentNaming

Conversation

@eerhardt

Copy link
Copy Markdown
Member

We should be prefixing the resources created via AddAzureContainerAppEnvironment with the environment name. This will allow for multiple environments to be in a single distributed application in the future.

With this change, it means deploying to existing environments will duplicate resources. To solve that, add a new method WithAzdResourceNaming, which will revert the resource names back to the previous naming scheme.

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
  • Does the change make any security assumptions or guarantees?
    • No
  • Does the change require an update in our Aspire docs?
    • No

…prefix
We should be prefixing the resources created via AddAzureContainerAppEnvironment with the environment name. This will allow for multiple environments to be in a single distributed application in the future.
With this change, it means deploying to existing environments will duplicate resources. To solve that, add a new method WithAzdResourceNaming, which will revert the resource names back to the previous naming scheme.
@eerhardt

Copy link
Copy Markdown
MemberAuthor

/backport to release/9.2

@github-actions

Copy link
Copy Markdown
Contributor

Started backporting to release/9.2: https://github.com/dotnet/aspire/actions/runs/14322106192

CopilotAI left a comment

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.

Copilot reviewed 3 out of 5 changed files in this pull request and generated 1 comment.

Files not reviewed (2)
  • playground/AzureContainerApps/AzureContainerApps.AppHost/infra.module.bicep: Language not supported
  • src/Aspire.Hosting.Azure.AppContainers/Aspire.Hosting.Azure.AppContainers.csproj: Language not supported

Comment threadtests/Aspire.Hosting.Azure.Tests/AzureContainerAppsTests.cs
@eerhardt

Copy link
Copy Markdown
MemberAuthor

/backport to release/9.2

@github-actions

Copy link
Copy Markdown
Contributor

Started backporting to release/9.2: https://github.com/dotnet/aspire/actions/runs/14323356917

@davidfowl
David Fowler (davidfowl) merged commit 0ec69cb into microsoft:mainApr 8, 2025
@davidfowl

Copy link
Copy Markdown
Collaborator

/backport to release/9.2

@github-actions

Copy link
Copy Markdown
Contributor

Started backporting to release/9.2: https://github.com/dotnet/aspire/actions/runs/14325206084

@github-actionsgithub-actionsBot locked and limited conversation to collaborators May 8, 2025
Sign up for freeto subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

area-integrationsIssues pertaining to Aspire Integrations packages

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@eerhardt@davidfowl