Skip to content

Commit

Permalink
Fix deprecation warning with IAM instance profile
Browse files Browse the repository at this point in the history
Instance profiles can only be associated with a single role. Here, the `roles`
attribute of `aws_iam_instance_profile` was updated to `role`.

See: hashicorp/terraform#13130
  • Loading branch information
hectcastro committed May 6, 2017
1 parent ebaf150 commit 4d14f0e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ resource "aws_iam_role_policy_attachment" "ec2_service_role" {
}

resource "aws_iam_instance_profile" "container_instance" {
name = "${aws_iam_role.container_instance_ec2.name}"
roles = ["${aws_iam_role.container_instance_ec2.name}"]
name = "${aws_iam_role.container_instance_ec2.name}"
role = "${aws_iam_role.container_instance_ec2.name}"
}

#
Expand Down

0 comments on commit 4d14f0e

Please sign in to comment.