Skip to content
Docs Try Aspire
Docs Try

AzureContainerAppExtensions

Class static net8.0
📦 Aspire.Hosting.Azure.AppContainers v13.4.0
Provides extension methods for customizing Azure Container App definitions for projects.
namespace Aspire.Hosting;
public static class AzureContainerAppExtensions
{
// ...
}
AddAzureContainerAppEnvironment(IDistributedApplicationBuilder, string)extensionats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Adds a container app environment resource to the distributed application builder.
AddAzureContainerAppsInfrastructure(IDistributedApplicationBuilder)extensionobsolete
IDistributedApplicationBuilder
Adds the necessary infrastructure for Azure Container Apps to the distributed application builder.
WithAcrPullIdentity(IResourceBuilder<AzureContainerAppEnvironmentResource>, IResourceBuilder<AzureUserAssignedIdentityResource>)extensionats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Configures the container app environment to use the supplied Azure.AzureUserAssignedIdentityResource as the managed identity that container apps in the environment use to pull images from the configured container registry (the AcrPull identity), instead of having Aspire create a new identity and a new AcrPull role assignment.
WithAzdResourceNaming(IResourceBuilder<AzureContainerAppEnvironmentResource>)extensionats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Configures the container app environment resources to use the same naming conventions as azd.
WithAzureLogAnalyticsWorkspace(IResourceBuilder<AzureContainerAppEnvironmentResource>, IResourceBuilder<AzureLogAnalyticsWorkspaceResource>)extensionats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Configures the container app environment resource to use the specified Log Analytics Workspace.
WithCompactResourceNaming(IResourceBuilder<AzureContainerAppEnvironmentResource>)extensionexperimentalats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Configures the container app environment to use compact resource naming that maximally preserves the uniqueString suffix for length-constrained Azure resources such as storage accounts.
WithDashboard(IResourceBuilder<AzureContainerAppEnvironmentResource>, bool)extensionats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Configures whether the Aspire dashboard should be included in the container app environment.
WithHttpsUpgrade(IResourceBuilder<AzureContainerAppEnvironmentResource>, bool)extensionats export
IResourceBuilder<AzureContainerAppEnvironmentResource>
Configures whether HTTP endpoints should be upgraded to HTTPS in Azure Container Apps. By default, HTTP endpoints are upgraded to HTTPS for security and WebSocket compatibility.
View all methods