Skip to content

Commit 994fe3f

Browse files
authored
Use aws_iam_role_policy_attachment instead of aws_iam_policy_attachment (#4)
* Bump `tf_label` to version `0.2.0` * Change `aws_iam_policy_attachment` to `aws_iam_role_policy_attachment`
1 parent e7a9c89 commit 994fe3f

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

main.tf

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Define composite variables for resources
22
module "label" {
3-
source = "git::https://github.com/cloudposse/tf_label.git?ref=tags/0.1.0"
3+
source = "git::https://github.com/cloudposse/tf_label.git?ref=tags/0.2.0"
44
namespace = "${var.namespace}"
55
name = "${var.name}"
66
stage = "${var.stage}"
@@ -47,21 +47,21 @@ data "aws_iam_policy_document" "permissions" {
4747
"ecr:GetAuthorizationToken",
4848
"ecr:InitiateLayerUpload",
4949
"ecr:PutImage",
50-
"ecr:UploadLayerPart"
50+
"ecr:UploadLayerPart",
5151
]
5252

5353
effect = "Allow"
5454

5555
resources = [
56-
"*"
56+
"*",
5757
]
5858
}
5959
}
6060

61-
resource "aws_iam_policy_attachment" "default" {
61+
resource "aws_iam_role_policy_attachment" "default" {
6262
name = "${module.label.id}"
6363
policy_arn = "${aws_iam_policy.default.arn}"
64-
roles = ["${aws_iam_role.default.id}"]
64+
role = "${aws_iam_role.default.id}"
6565
}
6666

6767
resource "aws_codebuild_project" "default" {

0 commit comments

Comments
 (0)