Volcengine v0.0.27 published on Tuesday, Dec 10, 2024 by Volcengine
volcengine.vpc.PrefixLists
Explore with Pulumi AI
Use this data source to query detailed information of vpc prefix lists
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@pulumi/volcengine";
import * as volcengine from "@volcengine/pulumi";
const fooPrefixList = new volcengine.vpc.PrefixList("fooPrefixList", {
    prefixListName: "acc-test-prefix",
    maxEntries: 3,
    description: "acc test description",
    ipVersion: "IPv4",
    prefixListEntries: [
        {
            cidr: "192.168.4.0/28",
            description: "acc-test-1",
        },
        {
            cidr: "192.168.5.0/28",
            description: "acc-test-2",
        },
    ],
    tags: [{
        key: "tf-key1",
        value: "tf-value1",
    }],
});
const fooPrefixLists = volcengine.vpc.PrefixListsOutput({
    ids: [fooPrefixList.id],
});
import pulumi
import pulumi_volcengine as volcengine
foo_prefix_list = volcengine.vpc.PrefixList("fooPrefixList",
    prefix_list_name="acc-test-prefix",
    max_entries=3,
    description="acc test description",
    ip_version="IPv4",
    prefix_list_entries=[
        volcengine.vpc.PrefixListPrefixListEntryArgs(
            cidr="192.168.4.0/28",
            description="acc-test-1",
        ),
        volcengine.vpc.PrefixListPrefixListEntryArgs(
            cidr="192.168.5.0/28",
            description="acc-test-2",
        ),
    ],
    tags=[volcengine.vpc.PrefixListTagArgs(
        key="tf-key1",
        value="tf-value1",
    )])
foo_prefix_lists = volcengine.vpc.prefix_lists_output(ids=[foo_prefix_list.id])
package main
import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vpc"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		fooPrefixList, err := vpc.NewPrefixList(ctx, "fooPrefixList", &vpc.PrefixListArgs{
			PrefixListName: pulumi.String("acc-test-prefix"),
			MaxEntries:     pulumi.Int(3),
			Description:    pulumi.String("acc test description"),
			IpVersion:      pulumi.String("IPv4"),
			PrefixListEntries: vpc.PrefixListPrefixListEntryArray{
				&vpc.PrefixListPrefixListEntryArgs{
					Cidr:        pulumi.String("192.168.4.0/28"),
					Description: pulumi.String("acc-test-1"),
				},
				&vpc.PrefixListPrefixListEntryArgs{
					Cidr:        pulumi.String("192.168.5.0/28"),
					Description: pulumi.String("acc-test-2"),
				},
			},
			Tags: vpc.PrefixListTagArray{
				&vpc.PrefixListTagArgs{
					Key:   pulumi.String("tf-key1"),
					Value: pulumi.String("tf-value1"),
				},
			},
		})
		if err != nil {
			return err
		}
		_ = vpc.PrefixListsOutput(ctx, vpc.PrefixListsOutputArgs{
			Ids: pulumi.StringArray{
				fooPrefixList.ID(),
			},
		}, nil)
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;
return await Deployment.RunAsync(() => 
{
    var fooPrefixList = new Volcengine.Vpc.PrefixList("fooPrefixList", new()
    {
        PrefixListName = "acc-test-prefix",
        MaxEntries = 3,
        Description = "acc test description",
        IpVersion = "IPv4",
        PrefixListEntries = new[]
        {
            new Volcengine.Vpc.Inputs.PrefixListPrefixListEntryArgs
            {
                Cidr = "192.168.4.0/28",
                Description = "acc-test-1",
            },
            new Volcengine.Vpc.Inputs.PrefixListPrefixListEntryArgs
            {
                Cidr = "192.168.5.0/28",
                Description = "acc-test-2",
            },
        },
        Tags = new[]
        {
            new Volcengine.Vpc.Inputs.PrefixListTagArgs
            {
                Key = "tf-key1",
                Value = "tf-value1",
            },
        },
    });
    var fooPrefixLists = Volcengine.Vpc.PrefixLists.Invoke(new()
    {
        Ids = new[]
        {
            fooPrefixList.Id,
        },
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.vpc.PrefixList;
import com.pulumi.volcengine.vpc.PrefixListArgs;
import com.pulumi.volcengine.vpc.inputs.PrefixListPrefixListEntryArgs;
import com.pulumi.volcengine.vpc.inputs.PrefixListTagArgs;
import com.pulumi.volcengine.vpc.VpcFunctions;
import com.pulumi.volcengine.vpc.inputs.PrefixListsArgs;
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) {
        var fooPrefixList = new PrefixList("fooPrefixList", PrefixListArgs.builder()        
            .prefixListName("acc-test-prefix")
            .maxEntries(3)
            .description("acc test description")
            .ipVersion("IPv4")
            .prefixListEntries(            
                PrefixListPrefixListEntryArgs.builder()
                    .cidr("192.168.4.0/28")
                    .description("acc-test-1")
                    .build(),
                PrefixListPrefixListEntryArgs.builder()
                    .cidr("192.168.5.0/28")
                    .description("acc-test-2")
                    .build())
            .tags(PrefixListTagArgs.builder()
                .key("tf-key1")
                .value("tf-value1")
                .build())
            .build());
        final var fooPrefixLists = VpcFunctions.PrefixLists(PrefixListsArgs.builder()
            .ids(fooPrefixList.id())
            .build());
    }
}
resources:
  fooPrefixList:
    type: volcengine:vpc:PrefixList
    properties:
      prefixListName: acc-test-prefix
      maxEntries: 3
      description: acc test description
      ipVersion: IPv4
      prefixListEntries:
        - cidr: 192.168.4.0/28
          description: acc-test-1
        - cidr: 192.168.5.0/28
          description: acc-test-2
      tags:
        - key: tf-key1
          value: tf-value1
variables:
  fooPrefixLists:
    fn::invoke:
      Function: volcengine:vpc:PrefixLists
      Arguments:
        ids:
          - ${fooPrefixList.id}
Using PrefixLists
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 prefixLists(args: PrefixListsArgs, opts?: InvokeOptions): Promise<PrefixListsResult>
function prefixListsOutput(args: PrefixListsOutputArgs, opts?: InvokeOptions): Output<PrefixListsResult>def prefix_lists(ids: Optional[Sequence[str]] = None,
                 ip_version: Optional[str] = None,
                 output_file: Optional[str] = None,
                 prefix_list_name: Optional[str] = None,
                 tag_filters: Optional[Sequence[PrefixListsTagFilter]] = None,
                 opts: Optional[InvokeOptions] = None) -> PrefixListsResult
def prefix_lists_output(ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
                 ip_version: Optional[pulumi.Input[str]] = None,
                 output_file: Optional[pulumi.Input[str]] = None,
                 prefix_list_name: Optional[pulumi.Input[str]] = None,
                 tag_filters: Optional[pulumi.Input[Sequence[pulumi.Input[PrefixListsTagFilterArgs]]]] = None,
                 opts: Optional[InvokeOptions] = None) -> Output[PrefixListsResult]func PrefixLists(ctx *Context, args *PrefixListsArgs, opts ...InvokeOption) (*PrefixListsResult, error)
func PrefixListsOutput(ctx *Context, args *PrefixListsOutputArgs, opts ...InvokeOption) PrefixListsResultOutputpublic static class PrefixLists 
{
    public static Task<PrefixListsResult> InvokeAsync(PrefixListsArgs args, InvokeOptions? opts = null)
    public static Output<PrefixListsResult> Invoke(PrefixListsInvokeArgs args, InvokeOptions? opts = null)
}public static CompletableFuture<PrefixListsResult> prefixLists(PrefixListsArgs args, InvokeOptions options)
public static Output<PrefixListsResult> prefixLists(PrefixListsArgs args, InvokeOptions options)
fn::invoke:
  function: volcengine:vpc:PrefixLists
  arguments:
    # arguments dictionaryThe following arguments are supported:
- Ids List<string>
- A list of prefix list ids.
- IpVersion string
- IP version of prefix list.
- OutputFile string
- File name where to save data source results.
- PrefixList stringName 
- A Name of prefix list.
- TagFilters List<PrefixLists Tag Filter> 
- List of tag filters.
- Ids []string
- A list of prefix list ids.
- IpVersion string
- IP version of prefix list.
- OutputFile string
- File name where to save data source results.
- PrefixList stringName 
- A Name of prefix list.
- TagFilters []PrefixLists Tag Filter 
- List of tag filters.
- ids List<String>
- A list of prefix list ids.
- ipVersion String
- IP version of prefix list.
- outputFile String
- File name where to save data source results.
- prefixList StringName 
- A Name of prefix list.
- tagFilters List<PrefixLists Tag Filter> 
- List of tag filters.
- ids string[]
- A list of prefix list ids.
- ipVersion string
- IP version of prefix list.
- outputFile string
- File name where to save data source results.
- prefixList stringName 
- A Name of prefix list.
- tagFilters PrefixLists Tag Filter[] 
- List of tag filters.
- ids Sequence[str]
- A list of prefix list ids.
- ip_version str
- IP version of prefix list.
- output_file str
- File name where to save data source results.
- prefix_list_ strname 
- A Name of prefix list.
- tag_filters Sequence[PrefixLists Tag Filter] 
- List of tag filters.
- ids List<String>
- A list of prefix list ids.
- ipVersion String
- IP version of prefix list.
- outputFile String
- File name where to save data source results.
- prefixList StringName 
- A Name of prefix list.
- tagFilters List<Property Map>
- List of tag filters.
PrefixLists Result
The following output properties are available:
- Id string
- The provider-assigned unique ID for this managed resource.
- PrefixLists List<PrefixLists Prefix List> 
- The collection of query.
- TotalCount int
- The total count of query.
- Ids List<string>
- IpVersion string
- The ip version of the prefix list.
- OutputFile string
- PrefixList stringName 
- The prefix list name.
- TagFilters List<PrefixLists Tag Filter> 
- Id string
- The provider-assigned unique ID for this managed resource.
- PrefixLists []PrefixLists Prefix List 
- The collection of query.
- TotalCount int
- The total count of query.
- Ids []string
- IpVersion string
- The ip version of the prefix list.
- OutputFile string
- PrefixList stringName 
- The prefix list name.
- TagFilters []PrefixLists Tag Filter 
- id String
- The provider-assigned unique ID for this managed resource.
- prefixLists List<PrefixLists Prefix List> 
- The collection of query.
- totalCount Integer
- The total count of query.
- ids List<String>
- ipVersion String
- The ip version of the prefix list.
- outputFile String
- prefixList StringName 
- The prefix list name.
- tagFilters List<PrefixLists Tag Filter> 
- id string
- The provider-assigned unique ID for this managed resource.
- prefixLists PrefixLists Prefix List[] 
- The collection of query.
- totalCount number
- The total count of query.
- ids string[]
- ipVersion string
- The ip version of the prefix list.
- outputFile string
- prefixList stringName 
- The prefix list name.
- tagFilters PrefixLists Tag Filter[] 
- id str
- The provider-assigned unique ID for this managed resource.
- prefix_lists Sequence[PrefixLists Prefix List] 
- The collection of query.
- total_count int
- The total count of query.
- ids Sequence[str]
- ip_version str
- The ip version of the prefix list.
- output_file str
- prefix_list_ strname 
- The prefix list name.
- tag_filters Sequence[PrefixLists Tag Filter] 
- id String
- The provider-assigned unique ID for this managed resource.
- prefixLists List<Property Map>
- The collection of query.
- totalCount Number
- The total count of query.
- ids List<String>
- ipVersion String
- The ip version of the prefix list.
- outputFile String
- prefixList StringName 
- The prefix list name.
- tagFilters List<Property Map>
Supporting Types
PrefixListsPrefixList   
- AssociationCount int
- Number of associated resources for prefix list.
- Cidrs List<string>
- CIDR address block information for prefix list.
- CreationTime string
- The creation time of the prefix list.
- Description string
- Description.
- Id string
- The id of the prefix list.
- IpVersion string
- IP version of prefix list.
- MaxEntries int
- Maximum number of entries, which is the maximum number of items that can be added to the prefix list.
- PrefixList List<PrefixAssociations Lists Prefix List Prefix List Association> 
- Collection of resources associated with VPC prefix list.
- PrefixList List<PrefixEntries Lists Prefix List Prefix List Entry> 
- The prefix list entries.
- PrefixList stringId 
- The prefix list id.
- PrefixList stringName 
- A Name of prefix list.
- Status string
- The status of the prefix list.
- UpdateTime string
- The update time of the prefix list.
- AssociationCount int
- Number of associated resources for prefix list.
- Cidrs []string
- CIDR address block information for prefix list.
- CreationTime string
- The creation time of the prefix list.
- Description string
- Description.
- Id string
- The id of the prefix list.
- IpVersion string
- IP version of prefix list.
- MaxEntries int
- Maximum number of entries, which is the maximum number of items that can be added to the prefix list.
- PrefixList []PrefixAssociations Lists Prefix List Prefix List Association 
- Collection of resources associated with VPC prefix list.
- PrefixList []PrefixEntries Lists Prefix List Prefix List Entry 
- The prefix list entries.
- PrefixList stringId 
- The prefix list id.
- PrefixList stringName 
- A Name of prefix list.
- Status string
- The status of the prefix list.
- UpdateTime string
- The update time of the prefix list.
- associationCount Integer
- Number of associated resources for prefix list.
- cidrs List<String>
- CIDR address block information for prefix list.
- creationTime String
- The creation time of the prefix list.
- description String
- Description.
- id String
- The id of the prefix list.
- ipVersion String
- IP version of prefix list.
- maxEntries Integer
- Maximum number of entries, which is the maximum number of items that can be added to the prefix list.
- prefixList List<PrefixAssociations Lists Prefix List Prefix List Association> 
- Collection of resources associated with VPC prefix list.
- prefixList List<PrefixEntries Lists Prefix List Prefix List Entry> 
- The prefix list entries.
- prefixList StringId 
- The prefix list id.
- prefixList StringName 
- A Name of prefix list.
- status String
- The status of the prefix list.
- updateTime String
- The update time of the prefix list.
- associationCount number
- Number of associated resources for prefix list.
- cidrs string[]
- CIDR address block information for prefix list.
- creationTime string
- The creation time of the prefix list.
- description string
- Description.
- id string
- The id of the prefix list.
- ipVersion string
- IP version of prefix list.
- maxEntries number
- Maximum number of entries, which is the maximum number of items that can be added to the prefix list.
- prefixList PrefixAssociations Lists Prefix List Prefix List Association[] 
- Collection of resources associated with VPC prefix list.
- prefixList PrefixEntries Lists Prefix List Prefix List Entry[] 
- The prefix list entries.
- prefixList stringId 
- The prefix list id.
- prefixList stringName 
- A Name of prefix list.
- status string
- The status of the prefix list.
- updateTime string
- The update time of the prefix list.
- association_count int
- Number of associated resources for prefix list.
- cidrs Sequence[str]
- CIDR address block information for prefix list.
- creation_time str
- The creation time of the prefix list.
- description str
- Description.
- id str
- The id of the prefix list.
- ip_version str
- IP version of prefix list.
- max_entries int
- Maximum number of entries, which is the maximum number of items that can be added to the prefix list.
- prefix_list_ Sequence[Prefixassociations Lists Prefix List Prefix List Association] 
- Collection of resources associated with VPC prefix list.
- prefix_list_ Sequence[Prefixentries Lists Prefix List Prefix List Entry] 
- The prefix list entries.
- prefix_list_ strid 
- The prefix list id.
- prefix_list_ strname 
- A Name of prefix list.
- status str
- The status of the prefix list.
- update_time str
- The update time of the prefix list.
- associationCount Number
- Number of associated resources for prefix list.
- cidrs List<String>
- CIDR address block information for prefix list.
- creationTime String
- The creation time of the prefix list.
- description String
- Description.
- id String
- The id of the prefix list.
- ipVersion String
- IP version of prefix list.
- maxEntries Number
- Maximum number of entries, which is the maximum number of items that can be added to the prefix list.
- prefixList List<Property Map>Associations 
- Collection of resources associated with VPC prefix list.
- prefixList List<Property Map>Entries 
- The prefix list entries.
- prefixList StringId 
- The prefix list id.
- prefixList StringName 
- A Name of prefix list.
- status String
- The status of the prefix list.
- updateTime String
- The update time of the prefix list.
PrefixListsPrefixListPrefixListAssociation      
- ResourceId string
- Associated resource ID.
- ResourceType string
- Related resource types.
- ResourceId string
- Associated resource ID.
- ResourceType string
- Related resource types.
- resourceId String
- Associated resource ID.
- resourceType String
- Related resource types.
- resourceId string
- Associated resource ID.
- resourceType string
- Related resource types.
- resource_id str
- Associated resource ID.
- resource_type str
- Related resource types.
- resourceId String
- Associated resource ID.
- resourceType String
- Related resource types.
PrefixListsPrefixListPrefixListEntry      
- Cidr string
- CIDR address blocks for prefix list entries.
- Description string
- Description.
- PrefixList stringId 
- The prefix list id.
- Cidr string
- CIDR address blocks for prefix list entries.
- Description string
- Description.
- PrefixList stringId 
- The prefix list id.
- cidr String
- CIDR address blocks for prefix list entries.
- description String
- Description.
- prefixList StringId 
- The prefix list id.
- cidr string
- CIDR address blocks for prefix list entries.
- description string
- Description.
- prefixList stringId 
- The prefix list id.
- cidr str
- CIDR address blocks for prefix list entries.
- description str
- Description.
- prefix_list_ strid 
- The prefix list id.
- cidr String
- CIDR address blocks for prefix list entries.
- description String
- Description.
- prefixList StringId 
- The prefix list id.
PrefixListsTagFilter   
Package Details
- Repository
- volcengine volcengine/pulumi-volcengine
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the volcengineTerraform Provider.