Skip to main content

managed_environments

Creates, updates, deletes, gets or lists a managed_environments resource.

Overview

Namemanaged_environments
TypeResource
Idazure.app_containers.managed_environments

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
idstringFully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}.
namestringThe name of the resource.
appLogsConfigurationobjectCluster configuration which enables the log daemon to export app logs to configured destination.
customDomainConfigurationobjectCustom domain configuration for the environment.
daprAIConnectionStringstringApplication Insights connection string used by Dapr to export Service to Service communication telemetry.
daprAIInstrumentationKeystringAzure Monitor instrumentation key used by Dapr to export Service to Service communication telemetry.
daprConfigurationobjectThe configuration of Dapr component.
defaultDomainstringDefault Domain Name for the cluster.
deploymentErrorsstringAny errors that occurred during deployment or deployment validation.
eventStreamEndpointstringThe endpoint of the eventstream of the Environment.
identityobjectThe managed service identities assigned to this resource.
infrastructureResourceGroupstringName of the platform-managed resource group created for the Managed Environment to host infrastructure resources. If a subnet ID is provided, this resource group will be created in the same subscription as the subnet.
ingressConfigurationobjectIngress configuration for the Managed Environment.
kedaConfigurationobjectThe configuration of Keda component.
kindstringKind of the Environment.
locationstringThe geo-location where the resource lives. Required.
peerAuthenticationobjectPeer authentication settings for the Managed Environment.
peerTrafficConfigurationobjectPeer traffic settings for the Managed Environment.
privateEndpointConnectionsarrayPrivate endpoint connections to the resource.
provisioningStatestringProvisioning state of the Environment. Known values are: "Succeeded", "Failed", "Canceled", "Waiting", "InitializationInProgress", "InfrastructureSetupInProgress", "InfrastructureSetupComplete", "ScheduledForDelete", "UpgradeRequested", and "UpgradeFailed". (Succeeded, Failed, Canceled, Waiting, InitializationInProgress, InfrastructureSetupInProgress, InfrastructureSetupComplete, ScheduledForDelete, UpgradeRequested, UpgradeFailed)
publicNetworkAccessstringProperty to allow or block all public traffic. Allowed Values: 'Enabled', 'Disabled'. Known values are: "Enabled" and "Disabled". (Enabled, Disabled)
staticIpstringStatic IP of the Environment.
systemDataobjectAzure Resource Manager metadata containing createdBy and modifiedBy information.
tagsobjectResource tags.
typestringThe type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts".
vnetConfigurationobjectVnet configuration for the environment.
workloadProfilesarrayWorkload profiles configured for the Managed Environment.
zoneRedundantbooleanWhether or not this Managed Environment is zone-redundant.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectresource_group_name, environment_name, subscription_idGet the properties of a Managed Environment. Get the properties of a Managed Environment used to host container apps.
list_by_resource_groupselectresource_group_name, subscription_idGet all the Environments in a resource group. Get all the Managed Environments in a resource group.
list_by_subscriptionselectsubscription_idGet all Environments for a subscription. Get all Managed Environments for a subscription.
create_or_updateinsertresource_group_name, environment_name, subscription_id, locationCreates or updates a Managed Environment. Creates or updates a Managed Environment used to host container apps.
updateupdateresource_group_name, environment_name, subscription_id, locationUpdate Managed Environment's properties. Patches a Managed Environment using JSON Merge Patch.
create_or_updatereplaceresource_group_name, environment_name, subscription_id, locationCreates or updates a Managed Environment. Creates or updates a Managed Environment used to host container apps.
deletedeleteresource_group_name, environment_name, subscription_idDelete a Managed Environment. Delete a Managed Environment if it does not have any container apps.
list_workload_profile_statesexecresource_group_name, environment_name, subscription_idGet all workload Profile States for a Managed Environment.. Get all workload Profile States for a Managed Environment.
get_auth_tokenexecresource_group_name, environment_name, subscription_idGet auth token for a managed environment. Checks if resource name is available.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
environment_namestringName of the Environment. Required.
resource_group_namestringThe name of the resource group. The name is case insensitive. Required.
subscription_idstring

SELECT examples

Get the properties of a Managed Environment. Get the properties of a Managed Environment used to host container apps.

SELECT
id,
name,
appLogsConfiguration,
customDomainConfiguration,
daprAIConnectionString,
daprAIInstrumentationKey,
daprConfiguration,
defaultDomain,
deploymentErrors,
eventStreamEndpoint,
identity,
infrastructureResourceGroup,
ingressConfiguration,
kedaConfiguration,
kind,
location,
peerAuthentication,
peerTrafficConfiguration,
privateEndpointConnections,
provisioningState,
publicNetworkAccess,
staticIp,
systemData,
tags,
type,
vnetConfiguration,
workloadProfiles,
zoneRedundant
FROM azure.app_containers.managed_environments
WHERE resource_group_name = '{{ resource_group_name }}' -- required
AND environment_name = '{{ environment_name }}' -- required
AND subscription_id = '{{ subscription_id }}' -- required
;

INSERT examples

Creates or updates a Managed Environment. Creates or updates a Managed Environment used to host container apps.

INSERT INTO azure.app_containers.managed_environments (
tags,
location,
properties,
kind,
identity,
resource_group_name,
environment_name,
subscription_id
)
SELECT
'{{ tags }}',
'{{ location }}' /* required */,
'{{ properties }}',
'{{ kind }}',
'{{ identity }}',
'{{ resource_group_name }}',
'{{ environment_name }}',
'{{ subscription_id }}'
RETURNING
id,
name,
identity,
kind,
location,
properties,
systemData,
tags,
type
;

UPDATE examples

Update Managed Environment's properties. Patches a Managed Environment using JSON Merge Patch.

UPDATE azure.app_containers.managed_environments
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
kind = '{{ kind }}',
identity = '{{ identity }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND environment_name = '{{ environment_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
identity,
kind,
location,
properties,
systemData,
tags,
type;

REPLACE examples

Creates or updates a Managed Environment. Creates or updates a Managed Environment used to host container apps.

REPLACE azure.app_containers.managed_environments
SET
tags = '{{ tags }}',
location = '{{ location }}',
properties = '{{ properties }}',
kind = '{{ kind }}',
identity = '{{ identity }}'
WHERE
resource_group_name = '{{ resource_group_name }}' --required
AND environment_name = '{{ environment_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
AND location = '{{ location }}' --required
RETURNING
id,
name,
identity,
kind,
location,
properties,
systemData,
tags,
type;

DELETE examples

Delete a Managed Environment. Delete a Managed Environment if it does not have any container apps.

DELETE FROM azure.app_containers.managed_environments
WHERE resource_group_name = '{{ resource_group_name }}' --required
AND environment_name = '{{ environment_name }}' --required
AND subscription_id = '{{ subscription_id }}' --required
;

Lifecycle Methods

Get all workload Profile States for a Managed Environment.. Get all workload Profile States for a Managed Environment.

EXEC azure.app_containers.managed_environments.list_workload_profile_states 
@resource_group_name='{{ resource_group_name }}' --required,
@environment_name='{{ environment_name }}' --required,
@subscription_id='{{ subscription_id }}' --required
;