github.com/vtorhonen/terraform@v0.9.0-beta2.0.20170307220345-5d894e4ffda7/website/source/docs/providers/aws/r/network_interface.markdown (about) 1 --- 2 layout: "aws" 3 page_title: "AWS: aws_network_interface" 4 sidebar_current: "docs-aws-resource-network-interface" 5 description: |- 6 Provides an Elastic network interface (ENI) resource. 7 --- 8 9 # aws\_network\_interface 10 11 Provides an Elastic network interface (ENI) resource. 12 13 ## Example Usage 14 15 ``` 16 resource "aws_network_interface" "test" { 17 subnet_id = "${aws_subnet.public_a.id}" 18 private_ips = ["10.0.0.50"] 19 security_groups = ["${aws_security_group.web.id}"] 20 21 attachment { 22 instance = "${aws_instance.test.id}" 23 device_index = 1 24 } 25 } 26 ``` 27 28 ## Argument Reference 29 30 The following arguments are supported: 31 32 * `subnet_id` - (Required) Subnet ID to create the ENI in. 33 * `description` - (Optional) A description for the network interface. 34 * `private_ips` - (Optional) List of private IPs to assign to the ENI. 35 * `security_groups` - (Optional) List of security group IDs to assign to the ENI. 36 * `attachment` - (Optional) Block to define the attachment of the ENI. Documented below. 37 * `source_dest_check` - (Optional) Whether to enable source destination checking for the ENI. Default true. 38 * `tags` - (Optional) A mapping of tags to assign to the resource. 39 40 The `attachment` block supports: 41 42 * `instance` - (Required) ID of the instance to attach to. 43 * `device_index` - (Required) Integer to define the devices index. 44 45 ## Attributes Reference 46 47 The following attributes are exported: 48 49 * `subnet_id` - Subnet ID the ENI is in. 50 * `description` - A description for the network interface. 51 * `private_ips` - List of private IPs assigned to the ENI. 52 * `security_groups` - List of security groups attached to the ENI. 53 * `attachment` - Block defining the attachment of the ENI. 54 * `source_dest_check` - Whether source destination checking is enabled 55 * `tags` - Tags assigned to the ENI. 56 57 58 59 ## Import 60 61 Network Interfaces can be imported using the `id`, e.g. 62 63 ``` 64 $ terraform import aws_network_interface.test eni-e5aa89a3 65 ```