Skip to content

Commit

Permalink
Merge pull request #6861 from granular-ryanbonham/DescribeLaunchTempl…
Browse files Browse the repository at this point in the history
…ateVersions

Support Scale from 0 with Lauch Templates
  • Loading branch information
k8s-ci-robot authored May 2, 2019
2 parents 8b9a91f + 54ef99e commit 06b81ae
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 7 deletions.
2 changes: 2 additions & 0 deletions pkg/model/iam/iam_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -739,6 +739,7 @@ func addMasterASPolicies(p *Policy, resource stringorslice.StringOrSlice, legacy
"autoscaling:SetDesiredCapacity",
"autoscaling:TerminateInstanceInAutoScalingGroup",
"autoscaling:UpdateAutoScalingGroup",
"ec2:DescribeLaunchTemplateVersions",
}),
Resource: resource,
})
Expand All @@ -752,6 +753,7 @@ func addMasterASPolicies(p *Policy, resource stringorslice.StringOrSlice, legacy
"autoscaling:DescribeAutoScalingGroups", // aws_instancegroups.go
"autoscaling:DescribeLaunchConfigurations", // aws.go
"autoscaling:DescribeTags", // auto_scaling.go
"ec2:DescribeLaunchTemplateVersions",
),
Resource: resource,
},
Expand Down
3 changes: 2 additions & 1 deletion pkg/model/iam/tests/iam_builder_master_legacy.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"autoscaling:DescribeTags",
"autoscaling:SetDesiredCapacity",
"autoscaling:TerminateInstanceInAutoScalingGroup",
"autoscaling:UpdateAutoScalingGroup"
"autoscaling:UpdateAutoScalingGroup",
"ec2:DescribeLaunchTemplateVersions"
],
"Resource": [
"*"
Expand Down
3 changes: 2 additions & 1 deletion pkg/model/iam/tests/iam_builder_master_strict.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@
"Action": [
"autoscaling:DescribeAutoScalingGroups",
"autoscaling:DescribeLaunchConfigurations",
"autoscaling:DescribeTags"
"autoscaling:DescribeTags",
"ec2:DescribeLaunchTemplateVersions"
],
"Resource": [
"*"
Expand Down
3 changes: 2 additions & 1 deletion pkg/model/iam/tests/iam_builder_master_strict_ecr.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,8 @@
"Action": [
"autoscaling:DescribeAutoScalingGroups",
"autoscaling:DescribeLaunchConfigurations",
"autoscaling:DescribeTags"
"autoscaling:DescribeTags",
"ec2:DescribeLaunchTemplateVersions"
],
"Resource": [
"*"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -691,7 +691,8 @@
"autoscaling:DescribeTags",
"autoscaling:SetDesiredCapacity",
"autoscaling:TerminateInstanceInAutoScalingGroup",
"autoscaling:UpdateAutoScalingGroup"
"autoscaling:UpdateAutoScalingGroup",
"ec2:DescribeLaunchTemplateVersions"
],
"Effect": "Allow",
"Resource": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,8 @@
"autoscaling:DescribeTags",
"autoscaling:SetDesiredCapacity",
"autoscaling:TerminateInstanceInAutoScalingGroup",
"autoscaling:UpdateAutoScalingGroup"
"autoscaling:UpdateAutoScalingGroup",
"ec2:DescribeLaunchTemplateVersions"
],
"Effect": "Allow",
"Resource": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -648,7 +648,8 @@
"autoscaling:DescribeTags",
"autoscaling:SetDesiredCapacity",
"autoscaling:TerminateInstanceInAutoScalingGroup",
"autoscaling:UpdateAutoScalingGroup"
"autoscaling:UpdateAutoScalingGroup",
"ec2:DescribeLaunchTemplateVersions"
],
"Effect": "Allow",
"Resource": [
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -639,7 +639,8 @@
"autoscaling:DescribeTags",
"autoscaling:SetDesiredCapacity",
"autoscaling:TerminateInstanceInAutoScalingGroup",
"autoscaling:UpdateAutoScalingGroup"
"autoscaling:UpdateAutoScalingGroup",
"ec2:DescribeLaunchTemplateVersions"
],
"Effect": "Allow",
"Resource": [
Expand Down

0 comments on commit 06b81ae

Please sign in to comment.