alicloud.vpc.getIpv6Addresses
Explore with Pulumi AI
This data source provides the Vpc Ipv6 Addresses of the current Alibaba Cloud user.
NOTE: Available in v1.142.0+.
Example Usage
Basic Usage
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var associatedInstanceId = AliCloud.Vpc.GetIpv6Addresses.Invoke(new()
{
AssociatedInstanceId = "example_value",
});
var vswitchId = AliCloud.Vpc.GetIpv6Addresses.Invoke(new()
{
VswitchId = "example_value",
});
var vpcId = AliCloud.Vpc.GetIpv6Addresses.Invoke(new()
{
VpcId = "example_value",
});
var status = AliCloud.Vpc.GetIpv6Addresses.Invoke(new()
{
Status = "Available",
});
return new Dictionary<string, object?>
{
["vpcIpv6AddressId1"] = associatedInstanceId.Apply(getIpv6AddressesResult => getIpv6AddressesResult.Addresses[0]?.Id),
["vpcIpv6AddressId2"] = vswitchId.Apply(getIpv6AddressesResult => getIpv6AddressesResult.Addresses[0]?.Id),
["vpcIpv6AddressId3"] = vpcId.Apply(getIpv6AddressesResult => getIpv6AddressesResult.Addresses[0]?.Id),
["vpcIpv6AddressId4"] = status.Apply(getIpv6AddressesResult => getIpv6AddressesResult.Addresses[0]?.Id),
};
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/vpc"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
associatedInstanceId, err := vpc.GetIpv6Addresses(ctx, &vpc.GetIpv6AddressesArgs{
AssociatedInstanceId: pulumi.StringRef("example_value"),
}, nil)
if err != nil {
return err
}
ctx.Export("vpcIpv6AddressId1", associatedInstanceId.Addresses[0].Id)
vswitchId, err := vpc.GetIpv6Addresses(ctx, &vpc.GetIpv6AddressesArgs{
VswitchId: pulumi.StringRef("example_value"),
}, nil)
if err != nil {
return err
}
ctx.Export("vpcIpv6AddressId2", vswitchId.Addresses[0].Id)
vpcId, err := vpc.GetIpv6Addresses(ctx, &vpc.GetIpv6AddressesArgs{
VpcId: pulumi.StringRef("example_value"),
}, nil)
if err != nil {
return err
}
ctx.Export("vpcIpv6AddressId3", vpcId.Addresses[0].Id)
status, err := vpc.GetIpv6Addresses(ctx, &vpc.GetIpv6AddressesArgs{
Status: pulumi.StringRef("Available"),
}, nil)
if err != nil {
return err
}
ctx.Export("vpcIpv6AddressId4", status.Addresses[0].Id)
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.vpc.VpcFunctions;
import com.pulumi.alicloud.vpc.inputs.GetIpv6AddressesArgs;
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 associatedInstanceId = VpcFunctions.getIpv6Addresses(GetIpv6AddressesArgs.builder()
.associatedInstanceId("example_value")
.build());
ctx.export("vpcIpv6AddressId1", associatedInstanceId.applyValue(getIpv6AddressesResult -> getIpv6AddressesResult.addresses()[0].id()));
final var vswitchId = VpcFunctions.getIpv6Addresses(GetIpv6AddressesArgs.builder()
.vswitchId("example_value")
.build());
ctx.export("vpcIpv6AddressId2", vswitchId.applyValue(getIpv6AddressesResult -> getIpv6AddressesResult.addresses()[0].id()));
final var vpcId = VpcFunctions.getIpv6Addresses(GetIpv6AddressesArgs.builder()
.vpcId("example_value")
.build());
ctx.export("vpcIpv6AddressId3", vpcId.applyValue(getIpv6AddressesResult -> getIpv6AddressesResult.addresses()[0].id()));
final var status = VpcFunctions.getIpv6Addresses(GetIpv6AddressesArgs.builder()
.status("Available")
.build());
ctx.export("vpcIpv6AddressId4", status.applyValue(getIpv6AddressesResult -> getIpv6AddressesResult.addresses()[0].id()));
}
}
import pulumi
import pulumi_alicloud as alicloud
associated_instance_id = alicloud.vpc.get_ipv6_addresses(associated_instance_id="example_value")
pulumi.export("vpcIpv6AddressId1", associated_instance_id.addresses[0].id)
vswitch_id = alicloud.vpc.get_ipv6_addresses(vswitch_id="example_value")
pulumi.export("vpcIpv6AddressId2", vswitch_id.addresses[0].id)
vpc_id = alicloud.vpc.get_ipv6_addresses(vpc_id="example_value")
pulumi.export("vpcIpv6AddressId3", vpc_id.addresses[0].id)
status = alicloud.vpc.get_ipv6_addresses(status="Available")
pulumi.export("vpcIpv6AddressId4", status.addresses[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const associatedInstanceId = alicloud.vpc.getIpv6Addresses({
associatedInstanceId: "example_value",
});
export const vpcIpv6AddressId1 = associatedInstanceId.then(associatedInstanceId => associatedInstanceId.addresses?.[0]?.id);
const vswitchId = alicloud.vpc.getIpv6Addresses({
vswitchId: "example_value",
});
export const vpcIpv6AddressId2 = vswitchId.then(vswitchId => vswitchId.addresses?.[0]?.id);
const vpcId = alicloud.vpc.getIpv6Addresses({
vpcId: "example_value",
});
export const vpcIpv6AddressId3 = vpcId.then(vpcId => vpcId.addresses?.[0]?.id);
const status = alicloud.vpc.getIpv6Addresses({
status: "Available",
});
export const vpcIpv6AddressId4 = status.then(status => status.addresses?.[0]?.id);
variables:
associatedInstanceId:
fn::invoke:
Function: alicloud:vpc:getIpv6Addresses
Arguments:
associatedInstanceId: example_value
vswitchId:
fn::invoke:
Function: alicloud:vpc:getIpv6Addresses
Arguments:
vswitchId: example_value
vpcId:
fn::invoke:
Function: alicloud:vpc:getIpv6Addresses
Arguments:
vpcId: example_value
status:
fn::invoke:
Function: alicloud:vpc:getIpv6Addresses
Arguments:
status: Available
outputs:
vpcIpv6AddressId1: ${associatedInstanceId.addresses[0].id}
vpcIpv6AddressId2: ${vswitchId.addresses[0].id}
vpcIpv6AddressId3: ${vpcId.addresses[0].id}
vpcIpv6AddressId4: ${status.addresses[0].id}
Using getIpv6Addresses
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 getIpv6Addresses(args: GetIpv6AddressesArgs, opts?: InvokeOptions): Promise<GetIpv6AddressesResult>
function getIpv6AddressesOutput(args: GetIpv6AddressesOutputArgs, opts?: InvokeOptions): Output<GetIpv6AddressesResult>
def get_ipv6_addresses(associated_instance_id: Optional[str] = None,
ids: Optional[Sequence[str]] = None,
output_file: Optional[str] = None,
status: Optional[str] = None,
vpc_id: Optional[str] = None,
vswitch_id: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetIpv6AddressesResult
def get_ipv6_addresses_output(associated_instance_id: Optional[pulumi.Input[str]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
output_file: Optional[pulumi.Input[str]] = None,
status: Optional[pulumi.Input[str]] = None,
vpc_id: Optional[pulumi.Input[str]] = None,
vswitch_id: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetIpv6AddressesResult]
func GetIpv6Addresses(ctx *Context, args *GetIpv6AddressesArgs, opts ...InvokeOption) (*GetIpv6AddressesResult, error)
func GetIpv6AddressesOutput(ctx *Context, args *GetIpv6AddressesOutputArgs, opts ...InvokeOption) GetIpv6AddressesResultOutput
> Note: This function is named GetIpv6Addresses
in the Go SDK.
public static class GetIpv6Addresses
{
public static Task<GetIpv6AddressesResult> InvokeAsync(GetIpv6AddressesArgs args, InvokeOptions? opts = null)
public static Output<GetIpv6AddressesResult> Invoke(GetIpv6AddressesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetIpv6AddressesResult> getIpv6Addresses(GetIpv6AddressesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:vpc/getIpv6Addresses:getIpv6Addresses
arguments:
# arguments dictionary
The following arguments are supported:
- Associated
Instance stringId The ID of the instance that is assigned the IPv6 address.
- Ids List<string>
- Output
File string File name where to save data source results (after running
pulumi preview
).- Status string
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- Vpc
Id string The ID of the VPC to which the IPv6 address belongs.
- Vswitch
Id string The ID of the vSwitch to which the IPv6 address belongs.
- Associated
Instance stringId The ID of the instance that is assigned the IPv6 address.
- Ids []string
- Output
File string File name where to save data source results (after running
pulumi preview
).- Status string
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- Vpc
Id string The ID of the VPC to which the IPv6 address belongs.
- Vswitch
Id string The ID of the vSwitch to which the IPv6 address belongs.
- associated
Instance StringId The ID of the instance that is assigned the IPv6 address.
- ids List<String>
- output
File String File name where to save data source results (after running
pulumi preview
).- status String
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc
Id String The ID of the VPC to which the IPv6 address belongs.
- vswitch
Id String The ID of the vSwitch to which the IPv6 address belongs.
- associated
Instance stringId The ID of the instance that is assigned the IPv6 address.
- ids string[]
- output
File string File name where to save data source results (after running
pulumi preview
).- status string
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc
Id string The ID of the VPC to which the IPv6 address belongs.
- vswitch
Id string The ID of the vSwitch to which the IPv6 address belongs.
- associated_
instance_ strid The ID of the instance that is assigned the IPv6 address.
- ids Sequence[str]
- output_
file str File name where to save data source results (after running
pulumi preview
).- status str
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc_
id str The ID of the VPC to which the IPv6 address belongs.
- vswitch_
id str The ID of the vSwitch to which the IPv6 address belongs.
- associated
Instance StringId The ID of the instance that is assigned the IPv6 address.
- ids List<String>
- output
File String File name where to save data source results (after running
pulumi preview
).- status String
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc
Id String The ID of the VPC to which the IPv6 address belongs.
- vswitch
Id String The ID of the vSwitch to which the IPv6 address belongs.
getIpv6Addresses Result
The following output properties are available:
- Addresses
List<Pulumi.
Ali Cloud. Vpc. Outputs. Get Ipv6Addresses Address> - Id string
The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Names List<string>
- Associated
Instance stringId - Output
File string - Status string
- Vpc
Id string - Vswitch
Id string
- Addresses
[]Get
Ipv6Addresses Address - Id string
The provider-assigned unique ID for this managed resource.
- Ids []string
- Names []string
- Associated
Instance stringId - Output
File string - Status string
- Vpc
Id string - Vswitch
Id string
- addresses
List<Get
Ipv6Addresses Address> - id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- associated
Instance StringId - output
File String - status String
- vpc
Id String - vswitch
Id String
- addresses
Get
Ipv6Addresses Address[] - id string
The provider-assigned unique ID for this managed resource.
- ids string[]
- names string[]
- associated
Instance stringId - output
File string - status string
- vpc
Id string - vswitch
Id string
- addresses
Sequence[Get
Ipv6Addresses Address] - id str
The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- names Sequence[str]
- associated_
instance_ strid - output_
file str - status str
- vpc_
id str - vswitch_
id str
- addresses List<Property Map>
- id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- associated
Instance StringId - output
File String - status String
- vpc
Id String - vswitch
Id String
Supporting Types
GetIpv6AddressesAddress
- Associated
Instance stringId The ID of the instance that is assigned the IPv6 address.
- Associated
Instance stringType The type of the instance that is assigned the IPv6 address.
- Create
Time string The time when the IPv6 address was created.
- Id string
The ID of the Ipv6 Address.
- Ipv6Address string
The address of the Ipv6 Address.
- Ipv6Address
Id string The ID of the IPv6 address.
- Ipv6Address
Name string The name of the IPv6 address.
- Ipv6Gateway
Id string The ID of the IPv6 gateway to which the IPv6 address belongs.
- Network
Type string The type of communication supported by the IPv6 address. Valid values:
Private
orPublic
.Private
: communication within the private network.Public
: communication over the public network- Status string
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- Vpc
Id string The ID of the VPC to which the IPv6 address belongs.
- Vswitch
Id string The ID of the vSwitch to which the IPv6 address belongs.
- Associated
Instance stringId The ID of the instance that is assigned the IPv6 address.
- Associated
Instance stringType The type of the instance that is assigned the IPv6 address.
- Create
Time string The time when the IPv6 address was created.
- Id string
The ID of the Ipv6 Address.
- Ipv6Address string
The address of the Ipv6 Address.
- Ipv6Address
Id string The ID of the IPv6 address.
- Ipv6Address
Name string The name of the IPv6 address.
- Ipv6Gateway
Id string The ID of the IPv6 gateway to which the IPv6 address belongs.
- Network
Type string The type of communication supported by the IPv6 address. Valid values:
Private
orPublic
.Private
: communication within the private network.Public
: communication over the public network- Status string
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- Vpc
Id string The ID of the VPC to which the IPv6 address belongs.
- Vswitch
Id string The ID of the vSwitch to which the IPv6 address belongs.
- associated
Instance StringId The ID of the instance that is assigned the IPv6 address.
- associated
Instance StringType The type of the instance that is assigned the IPv6 address.
- create
Time String The time when the IPv6 address was created.
- id String
The ID of the Ipv6 Address.
- ipv6Address String
The address of the Ipv6 Address.
- ipv6Address
Id String The ID of the IPv6 address.
- ipv6Address
Name String The name of the IPv6 address.
- ipv6Gateway
Id String The ID of the IPv6 gateway to which the IPv6 address belongs.
- network
Type String The type of communication supported by the IPv6 address. Valid values:
Private
orPublic
.Private
: communication within the private network.Public
: communication over the public network- status String
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc
Id String The ID of the VPC to which the IPv6 address belongs.
- vswitch
Id String The ID of the vSwitch to which the IPv6 address belongs.
- associated
Instance stringId The ID of the instance that is assigned the IPv6 address.
- associated
Instance stringType The type of the instance that is assigned the IPv6 address.
- create
Time string The time when the IPv6 address was created.
- id string
The ID of the Ipv6 Address.
- ipv6Address string
The address of the Ipv6 Address.
- ipv6Address
Id string The ID of the IPv6 address.
- ipv6Address
Name string The name of the IPv6 address.
- ipv6Gateway
Id string The ID of the IPv6 gateway to which the IPv6 address belongs.
- network
Type string The type of communication supported by the IPv6 address. Valid values:
Private
orPublic
.Private
: communication within the private network.Public
: communication over the public network- status string
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc
Id string The ID of the VPC to which the IPv6 address belongs.
- vswitch
Id string The ID of the vSwitch to which the IPv6 address belongs.
- associated_
instance_ strid The ID of the instance that is assigned the IPv6 address.
- associated_
instance_ strtype The type of the instance that is assigned the IPv6 address.
- create_
time str The time when the IPv6 address was created.
- id str
The ID of the Ipv6 Address.
- ipv6_
address str The address of the Ipv6 Address.
- ipv6_
address_ strid The ID of the IPv6 address.
- ipv6_
address_ strname The name of the IPv6 address.
- ipv6_
gateway_ strid The ID of the IPv6 gateway to which the IPv6 address belongs.
- network_
type str The type of communication supported by the IPv6 address. Valid values:
Private
orPublic
.Private
: communication within the private network.Public
: communication over the public network- status str
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc_
id str The ID of the VPC to which the IPv6 address belongs.
- vswitch_
id str The ID of the vSwitch to which the IPv6 address belongs.
- associated
Instance StringId The ID of the instance that is assigned the IPv6 address.
- associated
Instance StringType The type of the instance that is assigned the IPv6 address.
- create
Time String The time when the IPv6 address was created.
- id String
The ID of the Ipv6 Address.
- ipv6Address String
The address of the Ipv6 Address.
- ipv6Address
Id String The ID of the IPv6 address.
- ipv6Address
Name String The name of the IPv6 address.
- ipv6Gateway
Id String The ID of the IPv6 gateway to which the IPv6 address belongs.
- network
Type String The type of communication supported by the IPv6 address. Valid values:
Private
orPublic
.Private
: communication within the private network.Public
: communication over the public network- status String
The status of the IPv6 address. Valid values:
Pending
orAvailable
.- vpc
Id String The ID of the VPC to which the IPv6 address belongs.
- vswitch
Id String The ID of the vSwitch to which the IPv6 address belongs.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
alicloud
Terraform Provider.