Skip to content
This repository was archived by the owner on Jan 6, 2024. It is now read-only.

Commit 5fed5fe

Browse files
nickumia-reisysmogul
authored andcommitted
revert iam policy to 8dbdc9c
1 parent dd50a84 commit 5fed5fe

File tree

1 file changed

+5
-18
lines changed

1 file changed

+5
-18
lines changed

main.tf

+5-18
Original file line numberDiff line numberDiff line change
@@ -91,24 +91,12 @@ resource "aws_iam_policy" "this" {
9191
{
9292
"Effect": "Allow",
9393
"Action": [
94-
"iam:CreateServiceLinkedRole"
95-
],
96-
"Resource": "*",
97-
"Condition": {
98-
"StringEquals": {
99-
"iam:AWSServiceName": "elasticloadbalancing.amazonaws.com"
100-
}
101-
}
102-
},
103-
{
104-
"Effect": "Allow",
105-
"Action": [
94+
"iam:CreateServiceLinkedRole",
10695
"ec2:DescribeAccountAttributes",
10796
"ec2:DescribeAddresses",
10897
"ec2:DescribeAvailabilityZones",
10998
"ec2:DescribeInternetGateways",
11099
"ec2:DescribeVpcs",
111-
"ec2:DescribeVpcPeeringConnections",
112100
"ec2:DescribeSubnets",
113101
"ec2:DescribeSecurityGroups",
114102
"ec2:DescribeInstances",
@@ -191,8 +179,7 @@ resource "aws_iam_policy" "this" {
191179
"Resource": "arn:aws:ec2:*:*:security-group/*",
192180
"Condition": {
193181
"Null": {
194-
"aws:RequestTag/elbv2.k8s.aws/cluster": "true",
195-
"aws:ResourceTag/elbv2.k8s.aws/cluster": "false"
182+
"aws:ResourceTag/ingress.k8s.aws/cluster": "false"
196183
}
197184
}
198185
},
@@ -237,7 +224,8 @@ resource "aws_iam_policy" "this" {
237224
"Effect": "Allow",
238225
"Action": [
239226
"elasticloadbalancing:AddTags",
240-
"elasticloadbalancing:RemoveTags"
227+
"elasticloadbalancing:RemoveTags",
228+
"elasticloadbalancing:DeleteTargetGroup"
241229
],
242230
"Resource": [
243231
"arn:aws:elasticloadbalancing:*:*:targetgroup/*/*",
@@ -246,8 +234,7 @@ resource "aws_iam_policy" "this" {
246234
],
247235
"Condition": {
248236
"Null": {
249-
"aws:RequestTag/elbv2.k8s.aws/cluster": "true",
250-
"aws:ResourceTag/elbv2.k8s.aws/cluster": "false"
237+
"aws:ResourceTag/ingress.k8s.aws/cluster": "false"
251238
}
252239
}
253240
},

0 commit comments

Comments
 (0)