Skip to content

Commit

Permalink
Allow service role some actions necessary for ELB
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelbeaumont committed Jul 30, 2020
1 parent d497ee1 commit 3448f54
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions pkg/cfn/builder/iam.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,13 @@ func (c *ClusterResourceSet) addResourcesForIAM() {
c.rs.attachAllowPolicy("PolicyCloudWatchMetrics", refSR, "*", []string{
"cloudwatch:PutMetricData",
})
// These are potentially required for creating load balancers but aren't included in the
// AmazonEKSClusterPolicy
// See https://docs.aws.amazon.com/elasticloadbalancing/latest/userguide/elb-api-permissions.html#required-permissions-v2
// and weaveworks/eksctl#2488
c.rs.attachAllowPolicy("PolicyELBPermissions", refSR, "*", []string{
"ec2:DescribeAccountAttributes",
})

c.rs.defineOutputFromAtt(outputs.ClusterServiceRoleARN, "ServiceRole", "Arn", true, func(v string) error {
c.spec.IAM.ServiceRoleARN = &v
Expand Down

0 comments on commit 3448f54

Please sign in to comment.