github.com/ezbercih/terraform@v0.1.1-0.20140729011846-3c33865e0839/website/source/docs/providers/aws/r/subnet.html.markdown (about)

     1  ---
     2  layout: "aws"
     3  page_title: "AWS: aws_subnet"
     4  sidebar_current: "docs-aws-resource-subnet"
     5  ---
     6  
     7  # aws\_subnet
     8  
     9  Provides an VPC subnet resource.
    10  
    11  ## Example Usage
    12  
    13  ```
    14  resource "aws_subnet" "main" {
    15      vpc_id = "${aws_vpc.main.id}"
    16      cidr_block = "10.0.1.0/16"
    17  }
    18  ```
    19  
    20  ## Argument Reference
    21  
    22  The following arguments are supported:
    23  
    24  * `availability_zone`- (Optional) The AZ for the subnet.
    25  * `cidr_block` - (Required) The CIDR block for the subnet.
    26  * `vpc_id` - (Required) The VPC ID.
    27  
    28  ## Attributes Reference
    29  
    30  The following attributes are exported:
    31  
    32  * `id` - The ID of the subnet
    33  * `availability_zone`- The AZ for the subnet.
    34  * `cidr_block` - The CIDR block for the subnet.
    35  * `vpc_id` - The VPC ID.
    36