Merge pull request #1166 from suguru/f-aws-block-device-root-iops

providers/aws: iops in root device skipped when output state
This commit is contained in:
Paul Hinze 2015-03-10 14:29:23 -06:00
commit f3a786b084
1 changed files with 1 additions and 1 deletions

View File

@ -482,6 +482,7 @@ func resourceAwsInstanceRead(d *schema.ResourceData, meta interface{}) error {
blockDevice["device_name"] = blockDevices[vol.VolumeId].DeviceName blockDevice["device_name"] = blockDevices[vol.VolumeId].DeviceName
blockDevice["volume_type"] = vol.VolumeType blockDevice["volume_type"] = vol.VolumeType
blockDevice["volume_size"] = volSize blockDevice["volume_size"] = volSize
blockDevice["iops"] = vol.IOPS
blockDevice["delete_on_termination"] = blockDevice["delete_on_termination"] =
blockDevices[vol.VolumeId].DeleteOnTermination blockDevices[vol.VolumeId].DeleteOnTermination
@ -494,7 +495,6 @@ func resourceAwsInstanceRead(d *schema.ResourceData, meta interface{}) error {
blockDevice["snapshot_id"] = vol.SnapshotId blockDevice["snapshot_id"] = vol.SnapshotId
blockDevice["encrypted"] = vol.Encrypted blockDevice["encrypted"] = vol.Encrypted
blockDevice["iops"] = vol.IOPS
nonRootBlockDevices = append(nonRootBlockDevices, blockDevice) nonRootBlockDevices = append(nonRootBlockDevices, blockDevice)
} }
d.Set("block_device", nonRootBlockDevices) d.Set("block_device", nonRootBlockDevices)