Nutanix v0.0.52 published on Friday, Jun 7, 2024 by Piers Karsenbarg
nutanix.getSubnet
Explore with Pulumi AI
Provides a resource to create a subnet based on the input parameters. A subnet is a block of IP addresses.
Using getSubnet
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getSubnet(args: GetSubnetArgs, opts?: InvokeOptions): Promise<GetSubnetResult>
function getSubnetOutput(args: GetSubnetOutputArgs, opts?: InvokeOptions): Output<GetSubnetResult>def get_subnet(additional_filters: Optional[Sequence[GetSubnetAdditionalFilter]] = None,
               categories: Optional[Sequence[GetSubnetCategory]] = None,
               subnet_id: Optional[str] = None,
               subnet_name: Optional[str] = None,
               opts: Optional[InvokeOptions] = None) -> GetSubnetResult
def get_subnet_output(additional_filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetSubnetAdditionalFilterArgs]]]] = None,
               categories: Optional[pulumi.Input[Sequence[pulumi.Input[GetSubnetCategoryArgs]]]] = None,
               subnet_id: Optional[pulumi.Input[str]] = None,
               subnet_name: Optional[pulumi.Input[str]] = None,
               opts: Optional[InvokeOptions] = None) -> Output[GetSubnetResult]func LookupSubnet(ctx *Context, args *LookupSubnetArgs, opts ...InvokeOption) (*LookupSubnetResult, error)
func LookupSubnetOutput(ctx *Context, args *LookupSubnetOutputArgs, opts ...InvokeOption) LookupSubnetResultOutput> Note: This function is named LookupSubnet in the Go SDK.
public static class GetSubnet 
{
    public static Task<GetSubnetResult> InvokeAsync(GetSubnetArgs args, InvokeOptions? opts = null)
    public static Output<GetSubnetResult> Invoke(GetSubnetInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<GetSubnetResult> getSubnet(GetSubnetArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
  function: nutanix:index/getSubnet:getSubnet
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Additional
Filters List<PiersKarsenbarg. Nutanix. Inputs. Get Subnet Additional Filter>  - Additional filters to narrow down list of subnets.
 
- Categories
List<Piers
Karsenbarg. Nutanix. Inputs. Get Subnet Category>  - The API Version.
 - Subnet
Id string - (Optional) The ID for the subnet.
 
- Subnet
Name string - (Optional) The name for the subnet
 
- Additional
Filters []GetSubnet Additional Filter  - Additional filters to narrow down list of subnets.
 
- Categories
[]Get
Subnet Category  - The API Version.
 - Subnet
Id string - (Optional) The ID for the subnet.
 
- Subnet
Name string - (Optional) The name for the subnet
 
- additional
Filters List<GetSubnet Additional Filter>  - Additional filters to narrow down list of subnets.
 
- categories
List<Get
Subnet Category>  - The API Version.
 - subnet
Id String - (Optional) The ID for the subnet.
 
- subnet
Name String - (Optional) The name for the subnet
 
- additional
Filters GetSubnet Additional Filter[]  - Additional filters to narrow down list of subnets.
 
- categories
Get
Subnet Category[]  - The API Version.
 - subnet
Id string - (Optional) The ID for the subnet.
 
- subnet
Name string - (Optional) The name for the subnet
 
- additional_
filters Sequence[GetSubnet Additional Filter]  - Additional filters to narrow down list of subnets.
 
- categories
Sequence[Get
Subnet Category]  - The API Version.
 - subnet_
id str - (Optional) The ID for the subnet.
 
- subnet_
name str - (Optional) The name for the subnet
 
- additional
Filters List<Property Map> - Additional filters to narrow down list of subnets.
 
- categories List<Property Map>
 - The API Version.
 - subnet
Id String - (Optional) The ID for the subnet.
 
- subnet
Name String - (Optional) The name for the subnet
 
getSubnet Result
The following output properties are available:
- Api
Version string - Availability
Zone Dictionary<string, string>Reference  - The reference to a availability_zone.
 - Categories
List<Piers
Karsenbarg. Nutanix. Outputs. Get Subnet Category>  - The API Version.
 - Cluster
Name string - The name of a cluster.
 - Cluster
Uuid string - Default
Gateway stringIp  - Default gateway IP address.
 - Description string
 - A description for subnet.
 - Dhcp
Domain List<string>Name Server Lists  - Dhcp
Domain List<string>Search Lists  - DHCP domain search list for a subnet.
 - Dhcp
Options Dictionary<string, string> - Spec for defining DHCP options.
 - Dhcp
Server Dictionary<string, string>Address  - Host address.
 - Dhcp
Server intAddress Port  - Port Number.
 - Enable
Nat bool - Id string
 - The provider-assigned unique ID for this managed resource.
 - Ip
Config List<string>Pool List Ranges  - Is
External bool - Message
Lists List<PiersKarsenbarg. Nutanix. Outputs. Get Subnet Message List>  - Metadata Dictionary<string, string>
 - The subnet kind metadata.
 - Name string
 - the name(Optional).
 
- Network
Function Dictionary<string, string>Chain Reference  - The reference to a network_function_chain.
 - Owner
Reference Dictionary<string, string> - The reference to a user.
 - Prefix
Length int - (Optional). IP prefix length of the Subnet.
 
- Project
Reference Dictionary<string, string> - The reference to a project.
 - State string
 - The state of the subnet.
 
- Subnet
Ip string - Subnet IP address.
 - Subnet
Type string - The type of the subnet.
 - Vlan
Id int - VLAN assigned to the subnet.
 - Vpc
Reference Dictionary<string, string> - Vswitch
Name string - The name of the vswitch.
 - Additional
Filters List<PiersKarsenbarg. Nutanix. Outputs. Get Subnet Additional Filter>  - Additional filters to narrow down list of subnets.
 
- Subnet
Id string - Subnet
Name string 
- Api
Version string - Availability
Zone map[string]stringReference  - The reference to a availability_zone.
 - Categories
[]Get
Subnet Category  - The API Version.
 - Cluster
Name string - The name of a cluster.
 - Cluster
Uuid string - Default
Gateway stringIp  - Default gateway IP address.
 - Description string
 - A description for subnet.
 - Dhcp
Domain []stringName Server Lists  - Dhcp
Domain []stringSearch Lists  - DHCP domain search list for a subnet.
 - Dhcp
Options map[string]string - Spec for defining DHCP options.
 - Dhcp
Server map[string]stringAddress  - Host address.
 - Dhcp
Server intAddress Port  - Port Number.
 - Enable
Nat bool - Id string
 - The provider-assigned unique ID for this managed resource.
 - Ip
Config []stringPool List Ranges  - Is
External bool - Message
Lists []GetSubnet Message List  - Metadata map[string]string
 - The subnet kind metadata.
 - Name string
 - the name(Optional).
 
- Network
Function map[string]stringChain Reference  - The reference to a network_function_chain.
 - Owner
Reference map[string]string - The reference to a user.
 - Prefix
Length int - (Optional). IP prefix length of the Subnet.
 
- Project
Reference map[string]string - The reference to a project.
 - State string
 - The state of the subnet.
 
- Subnet
Ip string - Subnet IP address.
 - Subnet
Type string - The type of the subnet.
 - Vlan
Id int - VLAN assigned to the subnet.
 - Vpc
Reference map[string]string - Vswitch
Name string - The name of the vswitch.
 - Additional
Filters []GetSubnet Additional Filter  - Additional filters to narrow down list of subnets.
 
- Subnet
Id string - Subnet
Name string 
- api
Version String - availability
Zone Map<String,String>Reference  - The reference to a availability_zone.
 - categories
List<Get
Subnet Category>  - The API Version.
 - cluster
Name String - The name of a cluster.
 - cluster
Uuid String - default
Gateway StringIp  - Default gateway IP address.
 - description String
 - A description for subnet.
 - dhcp
Domain List<String>Name Server Lists  - dhcp
Domain List<String>Search Lists  - DHCP domain search list for a subnet.
 - dhcp
Options Map<String,String> - Spec for defining DHCP options.
 - dhcp
Server Map<String,String>Address  - Host address.
 - dhcp
Server IntegerAddress Port  - Port Number.
 - enable
Nat Boolean - id String
 - The provider-assigned unique ID for this managed resource.
 - ip
Config List<String>Pool List Ranges  - is
External Boolean - message
Lists List<GetSubnet Message List>  - metadata Map<String,String>
 - The subnet kind metadata.
 - name String
 - the name(Optional).
 
- network
Function Map<String,String>Chain Reference  - The reference to a network_function_chain.
 - owner
Reference Map<String,String> - The reference to a user.
 - prefix
Length Integer - (Optional). IP prefix length of the Subnet.
 
- project
Reference Map<String,String> - The reference to a project.
 - state String
 - The state of the subnet.
 
- subnet
Ip String - Subnet IP address.
 - subnet
Type String - The type of the subnet.
 - vlan
Id Integer - VLAN assigned to the subnet.
 - vpc
Reference Map<String,String> - vswitch
Name String - The name of the vswitch.
 - additional
Filters List<GetSubnet Additional Filter>  - Additional filters to narrow down list of subnets.
 
- subnet
Id String - subnet
Name String 
- api
Version string - availability
Zone {[key: string]: string}Reference  - The reference to a availability_zone.
 - categories
Get
Subnet Category[]  - The API Version.
 - cluster
Name string - The name of a cluster.
 - cluster
Uuid string - default
Gateway stringIp  - Default gateway IP address.
 - description string
 - A description for subnet.
 - dhcp
Domain string[]Name Server Lists  - dhcp
Domain string[]Search Lists  - DHCP domain search list for a subnet.
 - dhcp
Options {[key: string]: string} - Spec for defining DHCP options.
 - dhcp
Server {[key: string]: string}Address  - Host address.
 - dhcp
Server numberAddress Port  - Port Number.
 - enable
Nat boolean - id string
 - The provider-assigned unique ID for this managed resource.
 - ip
Config string[]Pool List Ranges  - is
External boolean - message
Lists GetSubnet Message List[]  - metadata {[key: string]: string}
 - The subnet kind metadata.
 - name string
 - the name(Optional).
 
- network
Function {[key: string]: string}Chain Reference  - The reference to a network_function_chain.
 - owner
Reference {[key: string]: string} - The reference to a user.
 - prefix
Length number - (Optional). IP prefix length of the Subnet.
 
- project
Reference {[key: string]: string} - The reference to a project.
 - state string
 - The state of the subnet.
 
- subnet
Ip string - Subnet IP address.
 - subnet
Type string - The type of the subnet.
 - vlan
Id number - VLAN assigned to the subnet.
 - vpc
Reference {[key: string]: string} - vswitch
Name string - The name of the vswitch.
 - additional
Filters GetSubnet Additional Filter[]  - Additional filters to narrow down list of subnets.
 
- subnet
Id string - subnet
Name string 
- api_
version str - availability_
zone_ Mapping[str, str]reference  - The reference to a availability_zone.
 - categories
Sequence[Get
Subnet Category]  - The API Version.
 - cluster_
name str - The name of a cluster.
 - cluster_
uuid str - default_
gateway_ strip  - Default gateway IP address.
 - description str
 - A description for subnet.
 - dhcp_
domain_ Sequence[str]name_ server_ lists  - dhcp_
domain_ Sequence[str]search_ lists  - DHCP domain search list for a subnet.
 - dhcp_
options Mapping[str, str] - Spec for defining DHCP options.
 - dhcp_
server_ Mapping[str, str]address  - Host address.
 - dhcp_
server_ intaddress_ port  - Port Number.
 - enable_
nat bool - id str
 - The provider-assigned unique ID for this managed resource.
 - ip_
config_ Sequence[str]pool_ list_ ranges  - is_
external bool - message_
lists Sequence[GetSubnet Message List]  - metadata Mapping[str, str]
 - The subnet kind metadata.
 - name str
 - the name(Optional).
 
- network_
function_ Mapping[str, str]chain_ reference  - The reference to a network_function_chain.
 - owner_
reference Mapping[str, str] - The reference to a user.
 - prefix_
length int - (Optional). IP prefix length of the Subnet.
 
- project_
reference Mapping[str, str] - The reference to a project.
 - state str
 - The state of the subnet.
 
- subnet_
ip str - Subnet IP address.
 - subnet_
type str - The type of the subnet.
 - vlan_
id int - VLAN assigned to the subnet.
 - vpc_
reference Mapping[str, str] - vswitch_
name str - The name of the vswitch.
 - additional_
filters Sequence[GetSubnet Additional Filter]  - Additional filters to narrow down list of subnets.
 
- subnet_
id str - subnet_
name str 
- api
Version String - availability
Zone Map<String>Reference  - The reference to a availability_zone.
 - categories List<Property Map>
 - The API Version.
 - cluster
Name String - The name of a cluster.
 - cluster
Uuid String - default
Gateway StringIp  - Default gateway IP address.
 - description String
 - A description for subnet.
 - dhcp
Domain List<String>Name Server Lists  - dhcp
Domain List<String>Search Lists  - DHCP domain search list for a subnet.
 - dhcp
Options Map<String> - Spec for defining DHCP options.
 - dhcp
Server Map<String>Address  - Host address.
 - dhcp
Server NumberAddress Port  - Port Number.
 - enable
Nat Boolean - id String
 - The provider-assigned unique ID for this managed resource.
 - ip
Config List<String>Pool List Ranges  - is
External Boolean - message
Lists List<Property Map> - metadata Map<String>
 - The subnet kind metadata.
 - name String
 - the name(Optional).
 
- network
Function Map<String>Chain Reference  - The reference to a network_function_chain.
 - owner
Reference Map<String> - The reference to a user.
 - prefix
Length Number - (Optional). IP prefix length of the Subnet.
 
- project
Reference Map<String> - The reference to a project.
 - state String
 - The state of the subnet.
 
- subnet
Ip String - Subnet IP address.
 - subnet
Type String - The type of the subnet.
 - vlan
Id Number - VLAN assigned to the subnet.
 - vpc
Reference Map<String> - vswitch
Name String - The name of the vswitch.
 - additional
Filters List<Property Map> - Additional filters to narrow down list of subnets.
 
- subnet
Id String - subnet
Name String 
Supporting Types
GetSubnetAdditionalFilter   
GetSubnetCategory  
GetSubnetMessageList   
Package Details
- Repository
 - nutanix pierskarsenbarg/pulumi-nutanix
 - License
 - Apache-2.0
 - Notes
 - This Pulumi package is based on the 
nutanixTerraform Provider.