github.com/vtorhonen/terraform@v0.9.0-beta2.0.20170307220345-5d894e4ffda7/website/source/docs/providers/aws/r/autoscaling_attachment.html.markdown (about) 1 --- 2 layout: "aws" 3 page_title: "AWS: aws_autoscaling_attachment" 4 sidebar_current: "docs-aws-resource-autoscaling-attachment" 5 description: |- 6 Provides an AutoScaling Group Attachment resource. 7 --- 8 9 # aws\_autoscaling\_attachment 10 11 Provides an AutoScaling Attachment resource. 12 13 ~> **NOTE on AutoScaling Groups and ASG Attachments:** Terraform currently provides 14 both a standalone ASG Attachment resource (describing an ASG attached to 15 an ELB), and an [AutoScaling Group resource](autoscaling_group.html) with 16 `load_balancers` defined in-line. At this time you cannot use an ASG with in-line 17 load balancers in conjunction with an ASG Attachment resource. Doing so will cause a 18 conflict and will overwrite attachments. 19 ## Example Usage 20 21 ``` 22 # Create a new load balancer attachment 23 resource "aws_autoscaling_attachment" "asg_attachment_bar" { 24 autoscaling_group_name = "${aws_autoscaling_group.asg.id}" 25 elb = "${aws_elb.bar.id}" 26 } 27 ``` 28 29 ## Argument Reference 30 31 The following arguments are supported: 32 33 * `autoscaling_group_name` - (Required) Name of ASG to associate with the ELB. 34 * `elb` - (Required) The name of the ELB. 35