Show / Hide Table of Contents

Class Subnet

Manages a subnet. Subnets represent network segments within the IP space defined by the virtual network.

NOTE on Virtual Networks and Subnet's: This provider currently provides both a standalone Subnet resource, and allows for Subnets to be defined in-line within the Virtual Network resource. At this time you cannot use a Virtual Network with in-line Subnets in conjunction with any Subnet resources. Doing so will cause a conflict of Subnet configurations and will overwrite Subnet's.

Inheritance
System.Object
Resource
CustomResource
Subnet
Inherited Members
CustomResource.Id
Resource.GetResourceType()
Resource.GetResourceName()
Resource.Urn
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Pulumi.Azure.Network
Assembly: Pulumi.Azure.dll
Syntax
public class Subnet : CustomResource

Constructors

View Source

Subnet(String, SubnetArgs, CustomResourceOptions)

Create a Subnet resource with the given unique name, arguments, and options.

Declaration
public Subnet(string name, SubnetArgs args, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resource

SubnetArgs args

The arguments used to populate this resource's properties

CustomResourceOptions options

A bag of options that control this resource's behavior

Properties

View Source

AddressPrefix

The address prefix to use for the subnet.

Declaration
public Output<string> AddressPrefix { get; }
Property Value
Type Description
Output<System.String>
View Source

AddressPrefixes

The address prefixes to use for the subnet.

Declaration
public Output<ImmutableArray<string>> AddressPrefixes { get; }
Property Value
Type Description
Output<System.Collections.Immutable.ImmutableArray<System.String>>
View Source

Delegations

One or more delegation blocks as defined below.

Declaration
public Output<ImmutableArray<SubnetDelegation>> Delegations { get; }
Property Value
Type Description
Output<System.Collections.Immutable.ImmutableArray<SubnetDelegation>>
View Source

EnforcePrivateLinkEndpointNetworkPolicies

Enable or Disable network policies for the private link endpoint on the subnet. Default value is false. Conflicts with enforce_private_link_service_network_policies.

Declaration
public Output<bool?> EnforcePrivateLinkEndpointNetworkPolicies { get; }
Property Value
Type Description
Output<System.Nullable<System.Boolean>>
View Source

EnforcePrivateLinkServiceNetworkPolicies

Enable or Disable network policies for the private link service on the subnet. Default valule is false. Conflicts with enforce_private_link_endpoint_network_policies.

Declaration
public Output<bool?> EnforcePrivateLinkServiceNetworkPolicies { get; }
Property Value
Type Description
Output<System.Nullable<System.Boolean>>
View Source

Name

The name of the subnet. Changing this forces a new resource to be created.

Declaration
public Output<string> Name { get; }
Property Value
Type Description
Output<System.String>
View Source

ResourceGroupName

The name of the resource group in which to create the subnet. Changing this forces a new resource to be created.

Declaration
public Output<string> ResourceGroupName { get; }
Property Value
Type Description
Output<System.String>
View Source

ServiceEndpoints

The list of Service endpoints to associate with the subnet. Possible values include: Microsoft.AzureActiveDirectory, Microsoft.AzureCosmosDB, Microsoft.ContainerRegistry, Microsoft.EventHub, Microsoft.KeyVault, Microsoft.ServiceBus, Microsoft.Sql, Microsoft.Storage and Microsoft.Web.

Declaration
public Output<ImmutableArray<string>> ServiceEndpoints { get; }
Property Value
Type Description
Output<System.Collections.Immutable.ImmutableArray<System.String>>
View Source

VirtualNetworkName

The name of the virtual network to which to attach the subnet. Changing this forces a new resource to be created.

Declaration
public Output<string> VirtualNetworkName { get; }
Property Value
Type Description
Output<System.String>

Methods

View Source

Get(String, Input<String>, SubnetState, CustomResourceOptions)

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

Declaration
public static Subnet Get(string name, Input<string> id, SubnetState state = null, CustomResourceOptions options = null)
Parameters
Type Name Description
System.String name

The unique name of the resulting resource.

Input<System.String> id

The unique provider ID of the resource to lookup.

SubnetState state

Any extra arguments used during the lookup.

CustomResourceOptions options

A bag of options that control this resource's behavior

Returns
Type Description
Subnet
  • View Source
Back to top Copyright 2016-2020, Pulumi Corporation.