alicloud_vpc_prefix_list

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.

Example Usage

Basic Usage

variable "name" {
  default = "tf-testacc-example"
}

resource "alicloud_resource_manager_resource_group" "defaultRg" {
  display_name        = "tf-testacc-chenyi"
  resource_group_name = var.name
}

resource "alicloud_resource_manager_resource_group" "changeRg" {
  display_name        = "tf-testacc-chenyi-change"
  resource_group_name = "${var.name}1"
}


resource "alicloud_vpc_prefix_list" "default" {
  max_entries             = 50
  resource_group_id       = alicloud_resource_manager_resource_group.defaultRg.id
  prefix_list_description = "test"
  ip_version              = "IPV4"
  prefix_list_name        = var.name
  entrys {
    cidr        = "192.168.0.0/16"
    description = "test"
  }
}

Argument Reference

The following arguments are supported:

Block Entrys

The Entries supports the following:

Attributes Reference

The following attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

Import

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

$ terraform import alicloud_vpc_prefix_list.example <id>