Skip to content

Commit

Permalink
reading the aws instance it was assumed that eth0 was the first in th…
Browse files Browse the repository at this point in the history
…e list of network interfaces
  • Loading branch information
Djuke committed May 30, 2016
1 parent e340348 commit c50025b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions builtin/providers/aws/resource_aws_instance.go
Original file line number Diff line number Diff line change
Expand Up @@ -501,6 +501,7 @@ func resourceAwsInstanceRead(d *schema.ResourceData, meta interface{}) error {
for _, ni := range instance.NetworkInterfaces {
if *ni.Attachment.DeviceIndex == 0 {
d.Set("subnet_id", ni.SubnetId)
d.Set("private_ips", flattenInstancePrivateIpAddresses(ni.PrivateIpAddresses))
}
}
} else {
Expand Down

0 comments on commit c50025b

Please sign in to comment.