PrefixList

class PrefixList : KotlinCustomResource

Provides a Vpc Prefix List resource. This resource is used to create a prefix list. For information about Vpc Prefix List and how to use it, see What is Prefix List.

NOTE: Available in v1.182.0+.

Example Usage

Basic Usage

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.resourcemanager.ResourceGroup;
import com.pulumi.alicloud.resourcemanager.ResourceGroupArgs;
import com.pulumi.alicloud.vpc.PrefixList;
import com.pulumi.alicloud.vpc.PrefixListArgs;
import com.pulumi.alicloud.vpc.inputs.PrefixListEntryArgs;
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 config = ctx.config();
final var name = config.get("name").orElse("tf-testacc-example");
var defaultRg = new ResourceGroup("defaultRg", ResourceGroupArgs.builder()
.displayName("tf-testacc-chenyi")
.resourceGroupName(name)
.build());
var changeRg = new ResourceGroup("changeRg", ResourceGroupArgs.builder()
.displayName("tf-testacc-chenyi-change")
.resourceGroupName(String.format("%s1", name))
.build());
var default_ = new PrefixList("default", PrefixListArgs.builder()
.maxEntries(50)
.resourceGroupId(defaultRg.id())
.prefixListDescription("test")
.ipVersion("IPV4")
.prefixListName(name)
.entrys(PrefixListEntryArgs.builder()
.cidr("192.168.0.0/16")
.description("test")
.build())
.build());
}
}

Import

Vpc Prefix List can be imported using the id, e.g.

$ pulumi import alicloud:vpc/prefixList:PrefixList example <id>

Properties

Link copied to clipboard
val createTime: Output<String>

The time when the prefix list was created.

Link copied to clipboard
val entrys: Output<List<PrefixListEntry>>?

The CIDR address block list of the prefix list.See the following Block Entrys.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val ipVersion: Output<String>

The IP version of the prefix list. Value:-IPV4:IPv4 version.-IPV6:IPv6 version.

Link copied to clipboard
val maxEntries: Output<Int>

The maximum number of entries for CIDR address blocks in the prefix list.

Link copied to clipboard

The association list information of the prefix list.

Link copied to clipboard

The description of the prefix list.It must be 2 to 256 characters in length and must start with a letter or Chinese, but cannot start with http:// or https://.

Link copied to clipboard
val prefixListId: Output<String>

The ID of the query Prefix List.

Link copied to clipboard
val prefixListName: Output<String>?

The name of the prefix list. The name must be 2 to 128 characters in length, and must start with a letter. It can contain digits, periods (.), underscores (_), and hyphens (-).

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val resourceGroupId: Output<String>

The ID of the resource group to which the PrefixList belongs.

Link copied to clipboard
val shareType: Output<String>

The share type of the prefix list. Value:-Shared: indicates that the prefix list is a Shared prefix list.-Null: indicates that the prefix list is not a shared prefix list.

Link copied to clipboard
val status: Output<String>

Resource attribute fields that represent the status of the resource.

Link copied to clipboard
val tags: Output<Map<String, Any>>?

The tags of PrefixList.

Link copied to clipboard
val urn: Output<String>