Vultr v2.19.0 published on Friday, Jan 5, 2024 by dirien
vultr.getPrivateNetwork
Explore with Pulumi AI
Get information about a Vultr private network.
Example Usage
Get the information for a private network by
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Vultr = Pulumi.Vultr;
return await Deployment.RunAsync(() =>
{
var myNetwork = Vultr.GetPrivateNetwork.Invoke(new()
{
Filters = new[]
{
new Vultr.Inputs.GetPrivateNetworkFilterInputArgs
{
Name = "description",
Values = new[]
{
"my-network-description",
},
},
},
});
});
package main
import (
"github.com/dirien/pulumi-vultr/sdk/v2/go/vultr"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := vultr.LookupPrivateNetwork(ctx, &vultr.LookupPrivateNetworkArgs{
Filters: []vultr.GetPrivateNetworkFilter{
{
Name: "description",
Values: []string{
"my-network-description",
},
},
},
}, nil)
if err != nil {
return err
}
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.vultr.VultrFunctions;
import com.pulumi.vultr.inputs.GetPrivateNetworkArgs;
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 myNetwork = VultrFunctions.getPrivateNetwork(GetPrivateNetworkArgs.builder()
.filters(GetPrivateNetworkFilterArgs.builder()
.name("description")
.values("my-network-description")
.build())
.build());
}
}
import pulumi
import pulumi_vultr as vultr
my_network = vultr.get_private_network(filters=[vultr.GetPrivateNetworkFilterArgs(
name="description",
values=["my-network-description"],
)])
import * as pulumi from "@pulumi/pulumi";
import * as vultr from "@pulumi/vultr";
const myNetwork = vultr.getPrivateNetwork({
filters: [{
name: "description",
values: ["my-network-description"],
}],
});
variables:
myNetwork:
fn::invoke:
Function: vultr:getPrivateNetwork
Arguments:
filters:
- name: description
values:
- my-network-description
Using getPrivateNetwork
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 getPrivateNetwork(args: GetPrivateNetworkArgs, opts?: InvokeOptions): Promise<GetPrivateNetworkResult>
function getPrivateNetworkOutput(args: GetPrivateNetworkOutputArgs, opts?: InvokeOptions): Output<GetPrivateNetworkResult>
def get_private_network(filters: Optional[Sequence[GetPrivateNetworkFilter]] = None,
opts: Optional[InvokeOptions] = None) -> GetPrivateNetworkResult
def get_private_network_output(filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetPrivateNetworkFilterArgs]]]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetPrivateNetworkResult]
func LookupPrivateNetwork(ctx *Context, args *LookupPrivateNetworkArgs, opts ...InvokeOption) (*LookupPrivateNetworkResult, error)
func LookupPrivateNetworkOutput(ctx *Context, args *LookupPrivateNetworkOutputArgs, opts ...InvokeOption) LookupPrivateNetworkResultOutput
> Note: This function is named LookupPrivateNetwork
in the Go SDK.
public static class GetPrivateNetwork
{
public static Task<GetPrivateNetworkResult> InvokeAsync(GetPrivateNetworkArgs args, InvokeOptions? opts = null)
public static Output<GetPrivateNetworkResult> Invoke(GetPrivateNetworkInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetPrivateNetworkResult> getPrivateNetwork(GetPrivateNetworkArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: vultr:index/getPrivateNetwork:getPrivateNetwork
arguments:
# arguments dictionary
The following arguments are supported:
- Filters
List<ediri.
Vultr. Inputs. Get Private Network Filter> - Query parameters for finding private networks.
- Filters
[]Get
Private Network Filter - Query parameters for finding private networks.
- filters
List<Get
Private Network Filter> - Query parameters for finding private networks.
- filters
Get
Private Network Filter[] - Query parameters for finding private networks.
- filters
Sequence[Get
Private Network Filter] - Query parameters for finding private networks.
- filters List<Property Map>
- Query parameters for finding private networks.
getPrivateNetwork Result
The following output properties are available:
- Date
Created string - The date the private network was added to your Vultr account.
- Description string
- The private network's description.
- Id string
- The provider-assigned unique ID for this managed resource.
- Region string
- The ID of the region that the private network is in.
- V4Subnet string
- The IPv4 network address. For example: 10.1.1.0.
- V4Subnet
Mask int - The number of bits for the netmask in CIDR notation. Example: 20
- Filters
List<ediri.
Vultr. Outputs. Get Private Network Filter>
- Date
Created string - The date the private network was added to your Vultr account.
- Description string
- The private network's description.
- Id string
- The provider-assigned unique ID for this managed resource.
- Region string
- The ID of the region that the private network is in.
- V4Subnet string
- The IPv4 network address. For example: 10.1.1.0.
- V4Subnet
Mask int - The number of bits for the netmask in CIDR notation. Example: 20
- Filters
[]Get
Private Network Filter
- date
Created String - The date the private network was added to your Vultr account.
- description String
- The private network's description.
- id String
- The provider-assigned unique ID for this managed resource.
- region String
- The ID of the region that the private network is in.
- v4Subnet String
- The IPv4 network address. For example: 10.1.1.0.
- v4Subnet
Mask Integer - The number of bits for the netmask in CIDR notation. Example: 20
- filters
List<Get
Private Network Filter>
- date
Created string - The date the private network was added to your Vultr account.
- description string
- The private network's description.
- id string
- The provider-assigned unique ID for this managed resource.
- region string
- The ID of the region that the private network is in.
- v4Subnet string
- The IPv4 network address. For example: 10.1.1.0.
- v4Subnet
Mask number - The number of bits for the netmask in CIDR notation. Example: 20
- filters
Get
Private Network Filter[]
- date_
created str - The date the private network was added to your Vultr account.
- description str
- The private network's description.
- id str
- The provider-assigned unique ID for this managed resource.
- region str
- The ID of the region that the private network is in.
- v4_
subnet str - The IPv4 network address. For example: 10.1.1.0.
- v4_
subnet_ intmask - The number of bits for the netmask in CIDR notation. Example: 20
- filters
Sequence[Get
Private Network Filter]
- date
Created String - The date the private network was added to your Vultr account.
- description String
- The private network's description.
- id String
- The provider-assigned unique ID for this managed resource.
- region String
- The ID of the region that the private network is in.
- v4Subnet String
- The IPv4 network address. For example: 10.1.1.0.
- v4Subnet
Mask Number - The number of bits for the netmask in CIDR notation. Example: 20
- filters List<Property Map>
Supporting Types
GetPrivateNetworkFilter
Package Details
- Repository
- vultr dirien/pulumi-vultr
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
vultr
Terraform Provider.