1. Packages
  2. Vcd Provider
  3. API Docs
  4. getNetworkIsolatedV2
vcd 3.14.1 published on Monday, Apr 14, 2025 by vmware

vcd.getNetworkIsolatedV2

Explore with Pulumi AI

Provides a VMware Cloud Director Org VDC isolated Network data source to read data or reference existing network.

Supported in provider v3.2+ for both NSX-T and NSX-V VDCs.

Example Usage

Looking Up Isolated Network In VDC)

import * as pulumi from "@pulumi/pulumi";
import * as vcd from "@pulumi/vcd";

const main = vcd.getOrgVdc({
    org: "my-org",
    name: "main-edge",
});
const net = main.then(main => vcd.getNetworkIsolatedV2({
    org: "my-org",
    ownerId: main.id,
    name: "my-net",
}));
Copy
import pulumi
import pulumi_vcd as vcd

main = vcd.get_org_vdc(org="my-org",
    name="main-edge")
net = vcd.get_network_isolated_v2(org="my-org",
    owner_id=main.id,
    name="my-net")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vcd/v3/vcd"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		main, err := vcd.LookupOrgVdc(ctx, &vcd.LookupOrgVdcArgs{
			Org:  pulumi.StringRef("my-org"),
			Name: "main-edge",
		}, nil)
		if err != nil {
			return err
		}
		_, err = vcd.LookupNetworkIsolatedV2(ctx, &vcd.LookupNetworkIsolatedV2Args{
			Org:     pulumi.StringRef("my-org"),
			OwnerId: pulumi.StringRef(main.Id),
			Name:    pulumi.StringRef("my-net"),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vcd = Pulumi.Vcd;

return await Deployment.RunAsync(() => 
{
    var main = Vcd.GetOrgVdc.Invoke(new()
    {
        Org = "my-org",
        Name = "main-edge",
    });

    var net = Vcd.GetNetworkIsolatedV2.Invoke(new()
    {
        Org = "my-org",
        OwnerId = main.Apply(getOrgVdcResult => getOrgVdcResult.Id),
        Name = "my-net",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vcd.VcdFunctions;
import com.pulumi.vcd.inputs.GetOrgVdcArgs;
import com.pulumi.vcd.inputs.GetNetworkIsolatedV2Args;
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) {
        final var main = VcdFunctions.getOrgVdc(GetOrgVdcArgs.builder()
            .org("my-org")
            .name("main-edge")
            .build());

        final var net = VcdFunctions.getNetworkIsolatedV2(GetNetworkIsolatedV2Args.builder()
            .org("my-org")
            .ownerId(main.applyValue(getOrgVdcResult -> getOrgVdcResult.id()))
            .name("my-net")
            .build());

    }
}
Copy
variables:
  main:
    fn::invoke:
      function: vcd:getOrgVdc
      arguments:
        org: my-org
        name: main-edge
  net:
    fn::invoke:
      function: vcd:getNetworkIsolatedV2
      arguments:
        org: my-org
        ownerId: ${main.id}
        name: my-net
Copy

Looking Up Isolated Network In VDC Group)

import * as pulumi from "@pulumi/pulumi";
import * as vcd from "@pulumi/vcd";

const main = vcd.getVdcGroup({
    org: "my-org",
    name: "main-group",
});
const net = main.then(main => vcd.getNetworkIsolatedV2({
    org: "my-org",
    ownerId: main.id,
    name: "my-net",
}));
Copy
import pulumi
import pulumi_vcd as vcd

main = vcd.get_vdc_group(org="my-org",
    name="main-group")
net = vcd.get_network_isolated_v2(org="my-org",
    owner_id=main.id,
    name="my-net")
Copy
package main

import (
	"github.com/pulumi/pulumi-terraform-provider/sdks/go/vcd/v3/vcd"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		main, err := vcd.LookupVdcGroup(ctx, &vcd.LookupVdcGroupArgs{
			Org:  pulumi.StringRef("my-org"),
			Name: pulumi.StringRef("main-group"),
		}, nil)
		if err != nil {
			return err
		}
		_, err = vcd.LookupNetworkIsolatedV2(ctx, &vcd.LookupNetworkIsolatedV2Args{
			Org:     pulumi.StringRef("my-org"),
			OwnerId: pulumi.StringRef(main.Id),
			Name:    pulumi.StringRef("my-net"),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vcd = Pulumi.Vcd;

return await Deployment.RunAsync(() => 
{
    var main = Vcd.GetVdcGroup.Invoke(new()
    {
        Org = "my-org",
        Name = "main-group",
    });

    var net = Vcd.GetNetworkIsolatedV2.Invoke(new()
    {
        Org = "my-org",
        OwnerId = main.Apply(getVdcGroupResult => getVdcGroupResult.Id),
        Name = "my-net",
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vcd.VcdFunctions;
import com.pulumi.vcd.inputs.GetVdcGroupArgs;
import com.pulumi.vcd.inputs.GetNetworkIsolatedV2Args;
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) {
        final var main = VcdFunctions.getVdcGroup(GetVdcGroupArgs.builder()
            .org("my-org")
            .name("main-group")
            .build());

        final var net = VcdFunctions.getNetworkIsolatedV2(GetNetworkIsolatedV2Args.builder()
            .org("my-org")
            .ownerId(main.applyValue(getVdcGroupResult -> getVdcGroupResult.id()))
            .name("my-net")
            .build());

    }
}
Copy
variables:
  main:
    fn::invoke:
      function: vcd:getVdcGroup
      arguments:
        org: my-org
        name: main-group
  net:
    fn::invoke:
      function: vcd:getNetworkIsolatedV2
      arguments:
        org: my-org
        ownerId: ${main.id}
        name: my-net
Copy

Filter arguments

  • name_regex - (Optional) matches the name using a regular expression.
  • ip - (Optional) matches the IP of the resource using a regular expression.

See Filters reference for details and examples.

Using getNetworkIsolatedV2

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 getNetworkIsolatedV2(args: GetNetworkIsolatedV2Args, opts?: InvokeOptions): Promise<GetNetworkIsolatedV2Result>
function getNetworkIsolatedV2Output(args: GetNetworkIsolatedV2OutputArgs, opts?: InvokeOptions): Output<GetNetworkIsolatedV2Result>
Copy
def get_network_isolated_v2(filter: Optional[GetNetworkIsolatedV2Filter] = None,
                            id: Optional[str] = None,
                            name: Optional[str] = None,
                            org: Optional[str] = None,
                            owner_id: Optional[str] = None,
                            vdc: Optional[str] = None,
                            opts: Optional[InvokeOptions] = None) -> GetNetworkIsolatedV2Result
def get_network_isolated_v2_output(filter: Optional[pulumi.Input[GetNetworkIsolatedV2FilterArgs]] = None,
                            id: Optional[pulumi.Input[str]] = None,
                            name: Optional[pulumi.Input[str]] = None,
                            org: Optional[pulumi.Input[str]] = None,
                            owner_id: Optional[pulumi.Input[str]] = None,
                            vdc: Optional[pulumi.Input[str]] = None,
                            opts: Optional[InvokeOptions] = None) -> Output[GetNetworkIsolatedV2Result]
Copy
func LookupNetworkIsolatedV2(ctx *Context, args *LookupNetworkIsolatedV2Args, opts ...InvokeOption) (*LookupNetworkIsolatedV2Result, error)
func LookupNetworkIsolatedV2Output(ctx *Context, args *LookupNetworkIsolatedV2OutputArgs, opts ...InvokeOption) LookupNetworkIsolatedV2ResultOutput
Copy

> Note: This function is named LookupNetworkIsolatedV2 in the Go SDK.

public static class GetNetworkIsolatedV2 
{
    public static Task<GetNetworkIsolatedV2Result> InvokeAsync(GetNetworkIsolatedV2Args args, InvokeOptions? opts = null)
    public static Output<GetNetworkIsolatedV2Result> Invoke(GetNetworkIsolatedV2InvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetNetworkIsolatedV2Result> getNetworkIsolatedV2(GetNetworkIsolatedV2Args args, InvokeOptions options)
public static Output<GetNetworkIsolatedV2Result> getNetworkIsolatedV2(GetNetworkIsolatedV2Args args, InvokeOptions options)
Copy
fn::invoke:
  function: vcd:index/getNetworkIsolatedV2:getNetworkIsolatedV2
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

Filter GetNetworkIsolatedV2Filter
Retrieves the data source using one or more filter parameters. Note filters do not support searching for networks in VDC Groups.
Id string
Name string
A unique name for the network (optional when filter is used)
Org string
The name of organization to use, optional if defined at provider level
OwnerId string
VDC or VDC Group ID. Always takes precedence over vdc fields (in resource and inherited from provider configuration)
Vdc string
The name of VDC to use. Deprecated in favor of new field owner_id which supports VDC and VDC Group IDs.

Deprecated: Deprecated

Filter GetNetworkIsolatedV2Filter
Retrieves the data source using one or more filter parameters. Note filters do not support searching for networks in VDC Groups.
Id string
Name string
A unique name for the network (optional when filter is used)
Org string
The name of organization to use, optional if defined at provider level
OwnerId string
VDC or VDC Group ID. Always takes precedence over vdc fields (in resource and inherited from provider configuration)
Vdc string
The name of VDC to use. Deprecated in favor of new field owner_id which supports VDC and VDC Group IDs.

Deprecated: Deprecated

filter GetNetworkIsolatedV2Filter
Retrieves the data source using one or more filter parameters. Note filters do not support searching for networks in VDC Groups.
id String
name String
A unique name for the network (optional when filter is used)
org String
The name of organization to use, optional if defined at provider level
ownerId String
VDC or VDC Group ID. Always takes precedence over vdc fields (in resource and inherited from provider configuration)
vdc String
The name of VDC to use. Deprecated in favor of new field owner_id which supports VDC and VDC Group IDs.

Deprecated: Deprecated

filter GetNetworkIsolatedV2Filter
Retrieves the data source using one or more filter parameters. Note filters do not support searching for networks in VDC Groups.
id string
name string
A unique name for the network (optional when filter is used)
org string
The name of organization to use, optional if defined at provider level
ownerId string
VDC or VDC Group ID. Always takes precedence over vdc fields (in resource and inherited from provider configuration)
vdc string
The name of VDC to use. Deprecated in favor of new field owner_id which supports VDC and VDC Group IDs.

Deprecated: Deprecated

filter GetNetworkIsolatedV2Filter
Retrieves the data source using one or more filter parameters. Note filters do not support searching for networks in VDC Groups.
id str
name str
A unique name for the network (optional when filter is used)
org str
The name of organization to use, optional if defined at provider level
owner_id str
VDC or VDC Group ID. Always takes precedence over vdc fields (in resource and inherited from provider configuration)
vdc str
The name of VDC to use. Deprecated in favor of new field owner_id which supports VDC and VDC Group IDs.

Deprecated: Deprecated

filter Property Map
Retrieves the data source using one or more filter parameters. Note filters do not support searching for networks in VDC Groups.
id String
name String
A unique name for the network (optional when filter is used)
org String
The name of organization to use, optional if defined at provider level
ownerId String
VDC or VDC Group ID. Always takes precedence over vdc fields (in resource and inherited from provider configuration)
vdc String
The name of VDC to use. Deprecated in favor of new field owner_id which supports VDC and VDC Group IDs.

Deprecated: Deprecated

getNetworkIsolatedV2 Result

The following output properties are available:

Supporting Types

GetNetworkIsolatedV2Filter

Ip string
Search by IP. The value can be a regular expression
NameRegex string
Search by name with a regular expression
Ip string
Search by IP. The value can be a regular expression
NameRegex string
Search by name with a regular expression
ip String
Search by IP. The value can be a regular expression
nameRegex String
Search by name with a regular expression
ip string
Search by IP. The value can be a regular expression
nameRegex string
Search by name with a regular expression
ip str
Search by IP. The value can be a regular expression
name_regex str
Search by name with a regular expression
ip String
Search by IP. The value can be a regular expression
nameRegex String
Search by name with a regular expression

GetNetworkIsolatedV2MetadataEntry

IsSystem This property is required. bool
Key This property is required. string
Type This property is required. string
UserAccess This property is required. string
Value This property is required. string
IsSystem This property is required. bool
Key This property is required. string
Type This property is required. string
UserAccess This property is required. string
Value This property is required. string
isSystem This property is required. Boolean
key This property is required. String
type This property is required. String
userAccess This property is required. String
value This property is required. String
isSystem This property is required. boolean
key This property is required. string
type This property is required. string
userAccess This property is required. string
value This property is required. string
is_system This property is required. bool
key This property is required. str
type This property is required. str
user_access This property is required. str
value This property is required. str
isSystem This property is required. Boolean
key This property is required. String
type This property is required. String
userAccess This property is required. String
value This property is required. String

GetNetworkIsolatedV2SecondaryStaticIpPool

EndAddress This property is required. string
StartAddress This property is required. string
EndAddress This property is required. string
StartAddress This property is required. string
endAddress This property is required. String
startAddress This property is required. String
endAddress This property is required. string
startAddress This property is required. string
end_address This property is required. str
start_address This property is required. str
endAddress This property is required. String
startAddress This property is required. String

GetNetworkIsolatedV2StaticIpPool

EndAddress This property is required. string
StartAddress This property is required. string
EndAddress This property is required. string
StartAddress This property is required. string
endAddress This property is required. String
startAddress This property is required. String
endAddress This property is required. string
startAddress This property is required. string
end_address This property is required. str
start_address This property is required. str
endAddress This property is required. String
startAddress This property is required. String

Package Details

Repository
vcd vmware/terraform-provider-vcd
License
Notes
This Pulumi package is based on the vcd Terraform Provider.