Azure Container Apps Managed Environment — ARM Preflight ValidationForResourceFailed (2025-07-01)

Mohanad Al Soloh 0 Reputation points
2026-11-15T18:31:51.6366667+00:00

Hello Microsoft Azure Container Apps team,

I am experiencing an ARM preflight validation failure when deploying an Azure Container Apps Managed Environment in Sweden Central.

Environment configuration

  • Resource type: Microsoft.App/managedEnvironments

API version: 2025-07-01

Region: swedencentral

Workload profile: Consumption

Environment type: Workload Profiles

Internal VNet integration: Enabled

Public network access: Disabled

Zone redundancy: Disabled

Infrastructure subnet: Existing subnet delegated to Microsoft.App/environments

Logging destination: Existing Azure Log Analytics workspace

Error details

The ARM deployment fails during preflight validation with:

InvalidTemplateDeployment

ValidationForResourceFailed

Resource provider: Microsoft.App/managedEnvironments

HTTP status: BadRequest

The original failure occurred on November 15, 2026, at approximately 18:02:56 UTC.

The Azure Activity Log confirms that Microsoft.Resources/deployments/validate/action failed.

Subsequent checks confirmed that the target managed environment was not created.

Troubleshooting already completed

Verified the ARM template is valid JSON.

Verified that the template uses Microsoft.App/managedEnvironments@2025-07-01.

Reviewed the configuration against the documented ARM resource schema.

Confirmed the infrastructure subnet is configured for Azure Container Apps.

Confirmed the existing Log Analytics workspace is provisioned.

Attempted ARM deployment validation, but the returned diagnostics did not expose the underlying resource provider error.

Questions

Are there known validation restrictions for creating an internal Workload Profiles environment with publicNetworkAccess=Disabled and a Consumption workload profile using API version 2025-07-01?

Are there additional networking or Log Analytics configuration requirements that could cause this preflight failure?

Is there a recommended way to retrieve the underlying Microsoft.App validation error when ARM only returns ValidationForResourceFailed?

Could this be a regional or API-version compatibility issue in Sweden Central?

I would appreciate guidance on identifying the precise root cause before making any configuration changes.

Thank you.Hello Microsoft Azure Container Apps team,

I am experiencing an ARM preflight validation failure when deploying an Azure Container Apps Managed Environment in Sweden Central.

Environment configuration

Resource type: Microsoft.App/managedEnvironments

API version: 2025-07-01

Region: swedencentral

Workload profile: Consumption

Environment type: Workload Profiles

Internal VNet integration: Enabled

Public network access: Disabled

Zone redundancy: Disabled

Infrastructure subnet: Existing subnet delegated to Microsoft.App/environments

Logging destination: Existing Azure Log Analytics workspace

Error details

The ARM deployment fails during preflight validation with:

InvalidTemplateDeployment

ValidationForResourceFailed

Resource provider: Microsoft.App/managedEnvironments

HTTP status: BadRequest

The original failure occurred on November 15, 2026, at approximately 18:02:56 UTC.

The Azure Activity Log confirms that Microsoft.Resources/deployments/validate/action failed.

Subsequent checks confirmed that the target managed environment was not created.

Troubleshooting already completed

Verified the ARM template is valid JSON.

Verified that the template uses Microsoft.App/managedEnvironments@2025-07-01.

Reviewed the configuration against the documented ARM resource schema.

Confirmed the infrastructure subnet is configured for Azure Container Apps.

Confirmed the existing Log Analytics workspace is provisioned.

Attempted ARM deployment validation, but the returned diagnostics did not expose the underlying resource provider error.

Questions

Are there known validation restrictions for creating an internal Workload Profiles environment with publicNetworkAccess=Disabled and a Consumption workload profile using API version 2025-07-01?

Are there additional networking or Log Analytics configuration requirements that could cause this preflight failure?

Is there a recommended way to retrieve the underlying Microsoft.App validation error when ARM only returns ValidationForResourceFailed?

Could this be a regional or API-version compatibility issue in Sweden Central?

I would appreciate guidance on identifying the precise root cause before making any configuration changes.

Thank you.

Azure Container Apps
Azure Container Apps

An Azure service that provides a general-purpose, serverless container platform.

0 comments No comments

4 answers

Sort by: Most helpful
  1. Mohanad Al Soloh 0 Reputation points
    2026-11-15T18:37:16.64+00:00

    Thank you for the guidance.

    I understand that deployment debug logging with ResponseContent may expose additional resource provider diagnostics.

    However, our ARM template uses listKeys() to resolve a Log Analytics shared key, and we must avoid persisting sensitive credentials in deployment history.

    Additionally, New-AzResourceGroupDeployment may create the managed environment, so we cannot use it solely for diagnosis without separate authorization.

    We have already confirmed the original failed ARM validation event with correlation ID:

    53634313-6523-4715-8f83-011fceae22a4

    Timestamp: 2026-11-15T18:02:56Z

    Could a Microsoft Azure Container Apps engineer advise whether the underlying Microsoft.App preflight validation error can be investigated using this correlation ID through provider-side telemetry?

    If that requires an official support case, please advise whether there is a no-cost escalation path for investigating this specific resource provider validation failure.

    We are seeking the exact rejected condition, without another deployment attempt or exposure of Log Analytics credentials.

    Thank you.

    Was this answer helpful?

    0 comments No comments

  2. Mohanad Al Soloh 0 Reputation points
    2026-11-15T18:36:08.3166667+00:00

    Thank you for the detailed guidance.

    We have confirmed that the environment was not created and that the original failure occurred during ARM preflight validation.

    Before proceeding with deployment debug logging, we have two security constraints:

    Our ARM template uses listKeys() to supply the Log Analytics shared key. We must avoid persisting credentials in deployment history or diagnostic logs.

    We cannot execute a new deployment solely for diagnosis without separate authorization, because it may create the managed environment.

    Is there a supported way to retrieve the underlying Microsoft.App preflight validation error using the existing correlation ID, without submitting a new deployment or enabling ResponseContent logging?

    Alternatively, is there a validation-only diagnostic method that exposes the resource provider's nested error without recording sensitive request or response content?

    We would prefer to exhaust these options before considering a new deployment.

    Thank you.

    Was this answer helpful?

    0 comments No comments

  3. Mohanad Al Soloh 0 Reputation points
    2026-11-15T18:35:26.7566667+00:00

    Thank you for the detailed guidance.

    We have confirmed that the environment was not created and that the original failure occurred during ARM preflight validation.

    Before proceeding with deployment debug logging, we have two security constraints:

    Our ARM template uses listKeys() to supply the Log Analytics shared key. We must avoid persisting credentials in deployment history or diagnostic logs.

    We cannot execute a new deployment solely for diagnosis without separate authorization, because it may create the managed environment.

    Is there a supported way to retrieve the underlying Microsoft.App preflight validation error using the existing correlation ID, without submitting a new deployment or enabling ResponseContent logging?

    Alternatively, is there a validation-only diagnostic method that exposes the resource provider's nested error without recording sensitive request or response content?

    We would prefer to exhaust these options before considering a new deployment.

    Thank you.

    Was this answer helpful?

    0 comments No comments

  4. AI answer

    2026-11-15T18:33:00.8066667+00:00

    The supported next step is to capture the deployment operation’s response payload with ARM debug logging, because the documented configuration supports an internal Workload Profiles environment with Consumption and disabled public access, while ValidationForResourceFailed alone does not identify the rejected condition.

    Capture the underlying Microsoft.App response

    Since ordinary validation and Activity Log output did not expose the nested error, submit the same template as a named deployment with response logging enabled. Debug logging can record secrets, including the Log Analytics shared key, so restrict access to the deployment history and delete it afterward. ^1^

    New-AzResourceGroupDeployment `
      -Name aca-env-debug `
      -ResourceGroupName '<resource-group>' `
      -TemplateFile '<template.json-or-main.bicep>' `
      -TemplateParameterFile '<parameters.json>' `
      -DeploymentDebugLogLevel ResponseContent
    

    PowerShell does not display the recorded request and response properties. Retrieve them with Azure CLI:

    az deployment operation group list \
      --resource-group <resource-group> \
      --name aca-env-debug \
      --query "[?properties.provisioningState=='Failed'].properties.{
        status:statusCode,
        message:statusMessage,
        response:response
      }" -o jsonc
    

    Also capture the correlation ID:

    az deployment group show \
      --resource-group <resource-group> \
      --name aca-env-debug \
      --query properties.correlationId -o tsv
    

    ARM deployment history exposes failed operation messages and correlation IDs used by Azure Support to trace provider-side operations. ^2^

    If the environment is inside a nested ARM deployment, add debugSetting.detailLevel to that nested Microsoft.Resources/deployments resource; top-level debug logging does not populate the nested deployment’s request and response. ^1^

    After collecting the result, remove the debug deployment history:

    az deployment group delete \
      --resource-group <resource-group> \
      --name aca-env-debug
    

    Configuration restrictions relevant to this topology

    There is no documented incompatibility among the settings listed:

    • Workload Profiles is the default environment type and includes a built-in Consumption profile. ^3^
    • An internal environment supports only publicNetworkAccess: Disabled; therefore, that combination is valid rather than contradictory. ^4^
    • Microsoft.App/managedEnvironments@2025-07-01 is a documented resource version and includes publicNetworkAccess, vnetConfiguration, workloadProfiles, and zoneRedundant. ^5^

    The networking requirements that can produce provider validation failures are:

    • A dedicated subnet used exclusively by the Container Apps environment.
    • At least /27 for a Workload Profiles environment.
    • Delegation to Microsoft.App/environments.
    • No overlap with the documented AKS-reserved and Container Apps platform-reserved ranges. ^6^

    Your subnet delegation check covers one of these requirements, but not necessarily subnet size, exclusivity, or address-range overlap. Use the nested error before changing any of them.

    For Log Analytics, when destination is log-analytics, the payload must contain logAnalyticsConfiguration.customerId and sharedKey; the shared key should be passed as a secure parameter. The Log Analytics object must not be supplied for another destination. ^5^ Merely confirming that the workspace exists does not confirm that these two submitted values are populated correctly.

    Region and API-version checks

    The available evidence does not establish a 2025-07-01 compatibility defect specific to Sweden Central. Confirm what the Microsoft.App provider advertises to this subscription:

    az provider show --namespace Microsoft.App \
      --query "resourceTypes[?resourceType=='managedEnvironments'].
        {locations:locations, apiVersions:apiVersions}" -o jsonc
    

    Provider metadata is the documented way to inspect valid locations and API versions for a resource type. Subscription restrictions can still prevent deployment in an otherwise supported region. ^7^

    Treat regional capacity as the cause only if the nested response identifies capacity. Capacity is distinct from quota; the documented responses are to use another supported region or retry later. If Sweden Central is mandatory, open a Container Apps support request with the UTC timestamp, full nested response, region, environment name, correlation ID, and operation ID. ^8^

    If debug logging still returns only the wrapper error, provider-side telemetry is required; the correlation and operation IDs are then the decisive artifacts for Support.


    References

    1. Enable debug logging
    2. View deployment history with Azure Resource Manager
    3. Workload profiles in Azure Container Apps
    4. Networking in an Azure Container Apps environment
    5. Microsoft.App managedEnvironments 2025-07-01 (deployment-language-arm-template)
    6. Virtual network configuration
    7. Azure resource providers and types
    8. Troubleshoot environment capacity errors in Azure Container Apps ...
    AI-generated content may be incorrect. Read our transparency notes for more information.

    Was this answer helpful?

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.