github.com/hobbeswalsh/terraform@v0.3.7-0.20150619183303-ad17cf55a0fa/website/source/docs/providers/aws/r/internet_gateway.html.markdown (about) 1 --- 2 layout: "aws" 3 page_title: "AWS: aws_internet_gateway" 4 sidebar_current: "docs-aws-resource-internet-gateway" 5 description: |- 6 Provides a resource to create a VPC Internet Gateway. 7 --- 8 9 # aws\_internet\_gateway 10 11 Provides a resource to create a VPC Internet Gateway. 12 13 ## Example Usage 14 15 ``` 16 resource "aws_internet_gateway" "gw" { 17 vpc_id = "${aws_vpc.main.id}" 18 19 tags { 20 Name = "main" 21 } 22 } 23 ``` 24 25 ## Argument Reference 26 27 The following arguments are supported: 28 29 * `vpc_id` - (Required) The VPC ID to create in. 30 * `tags` - (Optional) A mapping of tags to assign to the resource. 31 32 -> **Note:** It's recommended to denote that the AWS Instance or Elastic IP depends on the Internet Gateway. For example: 33 34 35 resource "aws_internet_gateway" "gw" { 36 vpc_id = "${aws_vpc.main.id}" 37 } 38 39 resource "aws_instance" "foo" { 40 depends_on = ["aws_internet_gateway.gw"] 41 } 42 43 44 ## Attributes Reference 45 46 The following attributes are exported: 47 48 * `id` - The ID of the Internet Gateway. 49