1. Packages
  2. Azure Classic
  3. API Docs
  4. appservice
  5. Environment

We recommend using Azure Native.

Azure Classic v5.81.0 published on Monday, Jun 24, 2024 by Pulumi

azure.appservice.Environment

Explore with Pulumi AI

azure logo

We recommend using Azure Native.

Azure Classic v5.81.0 published on Monday, Jun 24, 2024 by Pulumi

    Manages an App Service Environment.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const example = new azure.core.ResourceGroup("example", {
        name: "exampleRG1",
        location: "West Europe",
    });
    const exampleVirtualNetwork = new azure.network.VirtualNetwork("example", {
        name: "example-vnet1",
        location: example.location,
        resourceGroupName: example.name,
        addressSpaces: ["10.0.0.0/16"],
    });
    const ase = new azure.network.Subnet("ase", {
        name: "asesubnet",
        resourceGroupName: example.name,
        virtualNetworkName: exampleVirtualNetwork.name,
        addressPrefixes: ["10.0.1.0/24"],
    });
    const gateway = new azure.network.Subnet("gateway", {
        name: "gatewaysubnet",
        resourceGroupName: example.name,
        virtualNetworkName: exampleVirtualNetwork.name,
        addressPrefixes: ["10.0.2.0/24"],
    });
    const exampleEnvironment = new azure.appservice.Environment("example", {
        name: "example-ase",
        resourceGroupName: example.name,
        subnetId: ase.id,
        pricingTier: "I2",
        frontEndScaleFactor: 10,
        internalLoadBalancingMode: "Web, Publishing",
        allowedUserIpCidrs: [
            "11.22.33.44/32",
            "55.66.77.0/24",
        ],
        clusterSettings: [{
            name: "DisableTls1.0",
            value: "1",
        }],
    });
    
    import pulumi
    import pulumi_azure as azure
    
    example = azure.core.ResourceGroup("example",
        name="exampleRG1",
        location="West Europe")
    example_virtual_network = azure.network.VirtualNetwork("example",
        name="example-vnet1",
        location=example.location,
        resource_group_name=example.name,
        address_spaces=["10.0.0.0/16"])
    ase = azure.network.Subnet("ase",
        name="asesubnet",
        resource_group_name=example.name,
        virtual_network_name=example_virtual_network.name,
        address_prefixes=["10.0.1.0/24"])
    gateway = azure.network.Subnet("gateway",
        name="gatewaysubnet",
        resource_group_name=example.name,
        virtual_network_name=example_virtual_network.name,
        address_prefixes=["10.0.2.0/24"])
    example_environment = azure.appservice.Environment("example",
        name="example-ase",
        resource_group_name=example.name,
        subnet_id=ase.id,
        pricing_tier="I2",
        front_end_scale_factor=10,
        internal_load_balancing_mode="Web, Publishing",
        allowed_user_ip_cidrs=[
            "11.22.33.44/32",
            "55.66.77.0/24",
        ],
        cluster_settings=[azure.appservice.EnvironmentClusterSettingArgs(
            name="DisableTls1.0",
            value="1",
        )])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/appservice"
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/core"
    	"github.com/pulumi/pulumi-azure/sdk/v5/go/azure/network"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		example, err := core.NewResourceGroup(ctx, "example", &core.ResourceGroupArgs{
    			Name:     pulumi.String("exampleRG1"),
    			Location: pulumi.String("West Europe"),
    		})
    		if err != nil {
    			return err
    		}
    		exampleVirtualNetwork, err := network.NewVirtualNetwork(ctx, "example", &network.VirtualNetworkArgs{
    			Name:              pulumi.String("example-vnet1"),
    			Location:          example.Location,
    			ResourceGroupName: example.Name,
    			AddressSpaces: pulumi.StringArray{
    				pulumi.String("10.0.0.0/16"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		ase, err := network.NewSubnet(ctx, "ase", &network.SubnetArgs{
    			Name:               pulumi.String("asesubnet"),
    			ResourceGroupName:  example.Name,
    			VirtualNetworkName: exampleVirtualNetwork.Name,
    			AddressPrefixes: pulumi.StringArray{
    				pulumi.String("10.0.1.0/24"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = network.NewSubnet(ctx, "gateway", &network.SubnetArgs{
    			Name:               pulumi.String("gatewaysubnet"),
    			ResourceGroupName:  example.Name,
    			VirtualNetworkName: exampleVirtualNetwork.Name,
    			AddressPrefixes: pulumi.StringArray{
    				pulumi.String("10.0.2.0/24"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = appservice.NewEnvironment(ctx, "example", &appservice.EnvironmentArgs{
    			Name:                      pulumi.String("example-ase"),
    			ResourceGroupName:         example.Name,
    			SubnetId:                  ase.ID(),
    			PricingTier:               pulumi.String("I2"),
    			FrontEndScaleFactor:       pulumi.Int(10),
    			InternalLoadBalancingMode: pulumi.String("Web, Publishing"),
    			AllowedUserIpCidrs: pulumi.StringArray{
    				pulumi.String("11.22.33.44/32"),
    				pulumi.String("55.66.77.0/24"),
    			},
    			ClusterSettings: appservice.EnvironmentClusterSettingArray{
    				&appservice.EnvironmentClusterSettingArgs{
    					Name:  pulumi.String("DisableTls1.0"),
    					Value: pulumi.String("1"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Azure = Pulumi.Azure;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Azure.Core.ResourceGroup("example", new()
        {
            Name = "exampleRG1",
            Location = "West Europe",
        });
    
        var exampleVirtualNetwork = new Azure.Network.VirtualNetwork("example", new()
        {
            Name = "example-vnet1",
            Location = example.Location,
            ResourceGroupName = example.Name,
            AddressSpaces = new[]
            {
                "10.0.0.0/16",
            },
        });
    
        var ase = new Azure.Network.Subnet("ase", new()
        {
            Name = "asesubnet",
            ResourceGroupName = example.Name,
            VirtualNetworkName = exampleVirtualNetwork.Name,
            AddressPrefixes = new[]
            {
                "10.0.1.0/24",
            },
        });
    
        var gateway = new Azure.Network.Subnet("gateway", new()
        {
            Name = "gatewaysubnet",
            ResourceGroupName = example.Name,
            VirtualNetworkName = exampleVirtualNetwork.Name,
            AddressPrefixes = new[]
            {
                "10.0.2.0/24",
            },
        });
    
        var exampleEnvironment = new Azure.AppService.Environment("example", new()
        {
            Name = "example-ase",
            ResourceGroupName = example.Name,
            SubnetId = ase.Id,
            PricingTier = "I2",
            FrontEndScaleFactor = 10,
            InternalLoadBalancingMode = "Web, Publishing",
            AllowedUserIpCidrs = new[]
            {
                "11.22.33.44/32",
                "55.66.77.0/24",
            },
            ClusterSettings = new[]
            {
                new Azure.AppService.Inputs.EnvironmentClusterSettingArgs
                {
                    Name = "DisableTls1.0",
                    Value = "1",
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.azure.core.ResourceGroup;
    import com.pulumi.azure.core.ResourceGroupArgs;
    import com.pulumi.azure.network.VirtualNetwork;
    import com.pulumi.azure.network.VirtualNetworkArgs;
    import com.pulumi.azure.network.Subnet;
    import com.pulumi.azure.network.SubnetArgs;
    import com.pulumi.azure.appservice.Environment;
    import com.pulumi.azure.appservice.EnvironmentArgs;
    import com.pulumi.azure.appservice.inputs.EnvironmentClusterSettingArgs;
    import java.util.List;
    import java.util.ArrayList;
    import java.util.Map;
    import java.io.File;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    
    public class App {
        public static void main(String[] args) {
            Pulumi.run(App::stack);
        }
    
        public static void stack(Context ctx) {
            var example = new ResourceGroup("example", ResourceGroupArgs.builder()
                .name("exampleRG1")
                .location("West Europe")
                .build());
    
            var exampleVirtualNetwork = new VirtualNetwork("exampleVirtualNetwork", VirtualNetworkArgs.builder()
                .name("example-vnet1")
                .location(example.location())
                .resourceGroupName(example.name())
                .addressSpaces("10.0.0.0/16")
                .build());
    
            var ase = new Subnet("ase", SubnetArgs.builder()
                .name("asesubnet")
                .resourceGroupName(example.name())
                .virtualNetworkName(exampleVirtualNetwork.name())
                .addressPrefixes("10.0.1.0/24")
                .build());
    
            var gateway = new Subnet("gateway", SubnetArgs.builder()
                .name("gatewaysubnet")
                .resourceGroupName(example.name())
                .virtualNetworkName(exampleVirtualNetwork.name())
                .addressPrefixes("10.0.2.0/24")
                .build());
    
            var exampleEnvironment = new Environment("exampleEnvironment", EnvironmentArgs.builder()
                .name("example-ase")
                .resourceGroupName(example.name())
                .subnetId(ase.id())
                .pricingTier("I2")
                .frontEndScaleFactor(10)
                .internalLoadBalancingMode("Web, Publishing")
                .allowedUserIpCidrs(            
                    "11.22.33.44/32",
                    "55.66.77.0/24")
                .clusterSettings(EnvironmentClusterSettingArgs.builder()
                    .name("DisableTls1.0")
                    .value("1")
                    .build())
                .build());
    
        }
    }
    
    resources:
      example:
        type: azure:core:ResourceGroup
        properties:
          name: exampleRG1
          location: West Europe
      exampleVirtualNetwork:
        type: azure:network:VirtualNetwork
        name: example
        properties:
          name: example-vnet1
          location: ${example.location}
          resourceGroupName: ${example.name}
          addressSpaces:
            - 10.0.0.0/16
      ase:
        type: azure:network:Subnet
        properties:
          name: asesubnet
          resourceGroupName: ${example.name}
          virtualNetworkName: ${exampleVirtualNetwork.name}
          addressPrefixes:
            - 10.0.1.0/24
      gateway:
        type: azure:network:Subnet
        properties:
          name: gatewaysubnet
          resourceGroupName: ${example.name}
          virtualNetworkName: ${exampleVirtualNetwork.name}
          addressPrefixes:
            - 10.0.2.0/24
      exampleEnvironment:
        type: azure:appservice:Environment
        name: example
        properties:
          name: example-ase
          resourceGroupName: ${example.name}
          subnetId: ${ase.id}
          pricingTier: I2
          frontEndScaleFactor: 10
          internalLoadBalancingMode: Web, Publishing
          allowedUserIpCidrs:
            - 11.22.33.44/32
            - 55.66.77.0/24
          clusterSettings:
            - name: DisableTls1.0
              value: '1'
    

    Create Environment Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Environment(name: string, args: EnvironmentArgs, opts?: CustomResourceOptions);
    @overload
    def Environment(resource_name: str,
                    args: EnvironmentArgs,
                    opts: Optional[ResourceOptions] = None)
    
    @overload
    def Environment(resource_name: str,
                    opts: Optional[ResourceOptions] = None,
                    resource_group_name: Optional[str] = None,
                    subnet_id: Optional[str] = None,
                    allowed_user_ip_cidrs: Optional[Sequence[str]] = None,
                    cluster_settings: Optional[Sequence[EnvironmentClusterSettingArgs]] = None,
                    front_end_scale_factor: Optional[int] = None,
                    internal_load_balancing_mode: Optional[str] = None,
                    name: Optional[str] = None,
                    pricing_tier: Optional[str] = None,
                    tags: Optional[Mapping[str, str]] = None)
    func NewEnvironment(ctx *Context, name string, args EnvironmentArgs, opts ...ResourceOption) (*Environment, error)
    public Environment(string name, EnvironmentArgs args, CustomResourceOptions? opts = null)
    public Environment(String name, EnvironmentArgs args)
    public Environment(String name, EnvironmentArgs args, CustomResourceOptions options)
    
    type: azure:appservice:Environment
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args EnvironmentArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args EnvironmentArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args EnvironmentArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args EnvironmentArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args EnvironmentArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var environmentResource = new Azure.AppService.Environment("environmentResource", new()
    {
        ResourceGroupName = "string",
        SubnetId = "string",
        AllowedUserIpCidrs = new[]
        {
            "string",
        },
        ClusterSettings = new[]
        {
            new Azure.AppService.Inputs.EnvironmentClusterSettingArgs
            {
                Name = "string",
                Value = "string",
            },
        },
        FrontEndScaleFactor = 0,
        InternalLoadBalancingMode = "string",
        Name = "string",
        PricingTier = "string",
        Tags = 
        {
            { "string", "string" },
        },
    });
    
    example, err := appservice.NewEnvironment(ctx, "environmentResource", &appservice.EnvironmentArgs{
    	ResourceGroupName: pulumi.String("string"),
    	SubnetId:          pulumi.String("string"),
    	AllowedUserIpCidrs: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	ClusterSettings: appservice.EnvironmentClusterSettingArray{
    		&appservice.EnvironmentClusterSettingArgs{
    			Name:  pulumi.String("string"),
    			Value: pulumi.String("string"),
    		},
    	},
    	FrontEndScaleFactor:       pulumi.Int(0),
    	InternalLoadBalancingMode: pulumi.String("string"),
    	Name:                      pulumi.String("string"),
    	PricingTier:               pulumi.String("string"),
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    })
    
    var environmentResource = new Environment("environmentResource", EnvironmentArgs.builder()
        .resourceGroupName("string")
        .subnetId("string")
        .allowedUserIpCidrs("string")
        .clusterSettings(EnvironmentClusterSettingArgs.builder()
            .name("string")
            .value("string")
            .build())
        .frontEndScaleFactor(0)
        .internalLoadBalancingMode("string")
        .name("string")
        .pricingTier("string")
        .tags(Map.of("string", "string"))
        .build());
    
    environment_resource = azure.appservice.Environment("environmentResource",
        resource_group_name="string",
        subnet_id="string",
        allowed_user_ip_cidrs=["string"],
        cluster_settings=[azure.appservice.EnvironmentClusterSettingArgs(
            name="string",
            value="string",
        )],
        front_end_scale_factor=0,
        internal_load_balancing_mode="string",
        name="string",
        pricing_tier="string",
        tags={
            "string": "string",
        })
    
    const environmentResource = new azure.appservice.Environment("environmentResource", {
        resourceGroupName: "string",
        subnetId: "string",
        allowedUserIpCidrs: ["string"],
        clusterSettings: [{
            name: "string",
            value: "string",
        }],
        frontEndScaleFactor: 0,
        internalLoadBalancingMode: "string",
        name: "string",
        pricingTier: "string",
        tags: {
            string: "string",
        },
    });
    
    type: azure:appservice:Environment
    properties:
        allowedUserIpCidrs:
            - string
        clusterSettings:
            - name: string
              value: string
        frontEndScaleFactor: 0
        internalLoadBalancingMode: string
        name: string
        pricingTier: string
        resourceGroupName: string
        subnetId: string
        tags:
            string: string
    

    Environment Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Environment resource accepts the following input properties:

    ResourceGroupName string
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    SubnetId string

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    AllowedUserIpCidrs List<string>

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    ClusterSettings List<EnvironmentClusterSetting>
    Zero or more cluster_setting blocks as defined below.
    FrontEndScaleFactor int
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    InternalLoadBalancingMode string
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    Name string
    The name of the App Service Environment. Changing this forces a new resource to be created.
    PricingTier string
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    Tags Dictionary<string, string>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    ResourceGroupName string
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    SubnetId string

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    AllowedUserIpCidrs []string

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    ClusterSettings []EnvironmentClusterSettingArgs
    Zero or more cluster_setting blocks as defined below.
    FrontEndScaleFactor int
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    InternalLoadBalancingMode string
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    Name string
    The name of the App Service Environment. Changing this forces a new resource to be created.
    PricingTier string
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    Tags map[string]string
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    resourceGroupName String
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    subnetId String

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    allowedUserIpCidrs List<String>

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    clusterSettings List<EnvironmentClusterSetting>
    Zero or more cluster_setting blocks as defined below.
    frontEndScaleFactor Integer
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internalLoadBalancingMode String
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    name String
    The name of the App Service Environment. Changing this forces a new resource to be created.
    pricingTier String
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    tags Map<String,String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    resourceGroupName string
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    subnetId string

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    allowedUserIpCidrs string[]

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    clusterSettings EnvironmentClusterSetting[]
    Zero or more cluster_setting blocks as defined below.
    frontEndScaleFactor number
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internalLoadBalancingMode string
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    name string
    The name of the App Service Environment. Changing this forces a new resource to be created.
    pricingTier string
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    tags {[key: string]: string}
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    resource_group_name str
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    subnet_id str

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    allowed_user_ip_cidrs Sequence[str]

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    cluster_settings Sequence[EnvironmentClusterSettingArgs]
    Zero or more cluster_setting blocks as defined below.
    front_end_scale_factor int
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internal_load_balancing_mode str
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    name str
    The name of the App Service Environment. Changing this forces a new resource to be created.
    pricing_tier str
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    tags Mapping[str, str]
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    resourceGroupName String
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    subnetId String

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    allowedUserIpCidrs List<String>

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    clusterSettings List<Property Map>
    Zero or more cluster_setting blocks as defined below.
    frontEndScaleFactor Number
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internalLoadBalancingMode String
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    name String
    The name of the App Service Environment. Changing this forces a new resource to be created.
    pricingTier String
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    tags Map<String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Environment resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    InternalIpAddress string
    IP address of internal load balancer of the App Service Environment.
    Location string
    The location where the App Service Environment exists.
    OutboundIpAddresses List<string>
    List of outbound IP addresses of the App Service Environment.
    ServiceIpAddress string
    IP address of service endpoint of the App Service Environment.
    Id string
    The provider-assigned unique ID for this managed resource.
    InternalIpAddress string
    IP address of internal load balancer of the App Service Environment.
    Location string
    The location where the App Service Environment exists.
    OutboundIpAddresses []string
    List of outbound IP addresses of the App Service Environment.
    ServiceIpAddress string
    IP address of service endpoint of the App Service Environment.
    id String
    The provider-assigned unique ID for this managed resource.
    internalIpAddress String
    IP address of internal load balancer of the App Service Environment.
    location String
    The location where the App Service Environment exists.
    outboundIpAddresses List<String>
    List of outbound IP addresses of the App Service Environment.
    serviceIpAddress String
    IP address of service endpoint of the App Service Environment.
    id string
    The provider-assigned unique ID for this managed resource.
    internalIpAddress string
    IP address of internal load balancer of the App Service Environment.
    location string
    The location where the App Service Environment exists.
    outboundIpAddresses string[]
    List of outbound IP addresses of the App Service Environment.
    serviceIpAddress string
    IP address of service endpoint of the App Service Environment.
    id str
    The provider-assigned unique ID for this managed resource.
    internal_ip_address str
    IP address of internal load balancer of the App Service Environment.
    location str
    The location where the App Service Environment exists.
    outbound_ip_addresses Sequence[str]
    List of outbound IP addresses of the App Service Environment.
    service_ip_address str
    IP address of service endpoint of the App Service Environment.
    id String
    The provider-assigned unique ID for this managed resource.
    internalIpAddress String
    IP address of internal load balancer of the App Service Environment.
    location String
    The location where the App Service Environment exists.
    outboundIpAddresses List<String>
    List of outbound IP addresses of the App Service Environment.
    serviceIpAddress String
    IP address of service endpoint of the App Service Environment.

    Look up Existing Environment Resource

    Get an existing Environment resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: EnvironmentState, opts?: CustomResourceOptions): Environment
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            allowed_user_ip_cidrs: Optional[Sequence[str]] = None,
            cluster_settings: Optional[Sequence[EnvironmentClusterSettingArgs]] = None,
            front_end_scale_factor: Optional[int] = None,
            internal_ip_address: Optional[str] = None,
            internal_load_balancing_mode: Optional[str] = None,
            location: Optional[str] = None,
            name: Optional[str] = None,
            outbound_ip_addresses: Optional[Sequence[str]] = None,
            pricing_tier: Optional[str] = None,
            resource_group_name: Optional[str] = None,
            service_ip_address: Optional[str] = None,
            subnet_id: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None) -> Environment
    func GetEnvironment(ctx *Context, name string, id IDInput, state *EnvironmentState, opts ...ResourceOption) (*Environment, error)
    public static Environment Get(string name, Input<string> id, EnvironmentState? state, CustomResourceOptions? opts = null)
    public static Environment get(String name, Output<String> id, EnvironmentState state, CustomResourceOptions options)
    Resource lookup is not supported in YAML
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AllowedUserIpCidrs List<string>

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    ClusterSettings List<EnvironmentClusterSetting>
    Zero or more cluster_setting blocks as defined below.
    FrontEndScaleFactor int
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    InternalIpAddress string
    IP address of internal load balancer of the App Service Environment.
    InternalLoadBalancingMode string
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    Location string
    The location where the App Service Environment exists.
    Name string
    The name of the App Service Environment. Changing this forces a new resource to be created.
    OutboundIpAddresses List<string>
    List of outbound IP addresses of the App Service Environment.
    PricingTier string
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    ResourceGroupName string
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    ServiceIpAddress string
    IP address of service endpoint of the App Service Environment.
    SubnetId string

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    Tags Dictionary<string, string>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    AllowedUserIpCidrs []string

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    ClusterSettings []EnvironmentClusterSettingArgs
    Zero or more cluster_setting blocks as defined below.
    FrontEndScaleFactor int
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    InternalIpAddress string
    IP address of internal load balancer of the App Service Environment.
    InternalLoadBalancingMode string
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    Location string
    The location where the App Service Environment exists.
    Name string
    The name of the App Service Environment. Changing this forces a new resource to be created.
    OutboundIpAddresses []string
    List of outbound IP addresses of the App Service Environment.
    PricingTier string
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    ResourceGroupName string
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    ServiceIpAddress string
    IP address of service endpoint of the App Service Environment.
    SubnetId string

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    Tags map[string]string
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    allowedUserIpCidrs List<String>

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    clusterSettings List<EnvironmentClusterSetting>
    Zero or more cluster_setting blocks as defined below.
    frontEndScaleFactor Integer
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internalIpAddress String
    IP address of internal load balancer of the App Service Environment.
    internalLoadBalancingMode String
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    location String
    The location where the App Service Environment exists.
    name String
    The name of the App Service Environment. Changing this forces a new resource to be created.
    outboundIpAddresses List<String>
    List of outbound IP addresses of the App Service Environment.
    pricingTier String
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    resourceGroupName String
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    serviceIpAddress String
    IP address of service endpoint of the App Service Environment.
    subnetId String

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    tags Map<String,String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    allowedUserIpCidrs string[]

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    clusterSettings EnvironmentClusterSetting[]
    Zero or more cluster_setting blocks as defined below.
    frontEndScaleFactor number
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internalIpAddress string
    IP address of internal load balancer of the App Service Environment.
    internalLoadBalancingMode string
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    location string
    The location where the App Service Environment exists.
    name string
    The name of the App Service Environment. Changing this forces a new resource to be created.
    outboundIpAddresses string[]
    List of outbound IP addresses of the App Service Environment.
    pricingTier string
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    resourceGroupName string
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    serviceIpAddress string
    IP address of service endpoint of the App Service Environment.
    subnetId string

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    tags {[key: string]: string}
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    allowed_user_ip_cidrs Sequence[str]

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    cluster_settings Sequence[EnvironmentClusterSettingArgs]
    Zero or more cluster_setting blocks as defined below.
    front_end_scale_factor int
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internal_ip_address str
    IP address of internal load balancer of the App Service Environment.
    internal_load_balancing_mode str
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    location str
    The location where the App Service Environment exists.
    name str
    The name of the App Service Environment. Changing this forces a new resource to be created.
    outbound_ip_addresses Sequence[str]
    List of outbound IP addresses of the App Service Environment.
    pricing_tier str
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    resource_group_name str
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    service_ip_address str
    IP address of service endpoint of the App Service Environment.
    subnet_id str

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    tags Mapping[str, str]
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    allowedUserIpCidrs List<String>

    Allowed user added IP ranges on the ASE database. Use the addresses you want to set as the explicit egress address ranges.

    NOTE: allowed_user_ip_cidrs The addresses that will be used for all outbound traffic from your App Service Environment to the internet to avoid asymmetric routing challenge. If you're routing the traffic on premises, these addresses are your NATs or gateway IPs. If you want to route the App Service Environment outbound traffic through an NVA, the egress address is the public IP of the NVA. Please visit Create your ASE with the egress addresses

    clusterSettings List<Property Map>
    Zero or more cluster_setting blocks as defined below.
    frontEndScaleFactor Number
    Scale factor for front end instances. Possible values are between 5 and 15. Defaults to 15.
    internalIpAddress String
    IP address of internal load balancer of the App Service Environment.
    internalLoadBalancingMode String
    Specifies which endpoints to serve internally in the Virtual Network for the App Service Environment. Possible values are None, Web, Publishing and combined value "Web, Publishing". Defaults to None. Changing this forces a new resource to be created.
    location String
    The location where the App Service Environment exists.
    name String
    The name of the App Service Environment. Changing this forces a new resource to be created.
    outboundIpAddresses List<String>
    List of outbound IP addresses of the App Service Environment.
    pricingTier String
    Pricing tier for the front end instances. Possible values are I1, I2 and I3. Defaults to I1.
    resourceGroupName String
    The name of the Resource Group where the App Service Environment exists. Defaults to the Resource Group of the Subnet (specified by subnet_id).
    serviceIpAddress String
    IP address of service endpoint of the App Service Environment.
    subnetId String

    The ID of the Subnet which the App Service Environment should be connected to. Changing this forces a new resource to be created.

    NOTE a /24 or larger CIDR is required. Once associated with an ASE this size cannot be changed.

    tags Map<String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.

    Supporting Types

    EnvironmentClusterSetting, EnvironmentClusterSettingArgs

    Name string
    The name of the Cluster Setting.
    Value string
    The value for the Cluster Setting.
    Name string
    The name of the Cluster Setting.
    Value string
    The value for the Cluster Setting.
    name String
    The name of the Cluster Setting.
    value String
    The value for the Cluster Setting.
    name string
    The name of the Cluster Setting.
    value string
    The value for the Cluster Setting.
    name str
    The name of the Cluster Setting.
    value str
    The value for the Cluster Setting.
    name String
    The name of the Cluster Setting.
    value String
    The value for the Cluster Setting.

    Import

    The App Service Environment can be imported using the resource id, e.g.

    $ pulumi import azure:appservice/environment:Environment myAppServiceEnv /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Web/hostingEnvironments/myAppServiceEnv
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Azure Classic v5.81.0 published on Monday, Jun 24, 2024 by Pulumi