Skip to content

Commit

Permalink
fix(0.35.x): discover deprecated EKS optimized AMIs (#7243)
Browse files Browse the repository at this point in the history
  • Loading branch information
jmdeal authored Oct 22, 2024
1 parent af9608c commit bddb3d9
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions pkg/providers/amifamily/ami.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,9 @@ func (p *Provider) getDefaultAMIs(ctx context.Context, nodeClass *v1beta1.EC2Nod
}
// Resolve Name and CreationDate information into the DefaultAMIs
if err = p.ec2api.DescribeImagesPagesWithContext(ctx, &ec2.DescribeImagesInput{
Filters: []*ec2.Filter{{Name: aws.String("image-id"), Values: aws.StringSlice(lo.Map(res, func(a AMI, _ int) string { return a.AmiID }))}},
MaxResults: aws.Int64(500),
Filters: []*ec2.Filter{{Name: aws.String("image-id"), Values: aws.StringSlice(lo.Map(res, func(a AMI, _ int) string { return a.AmiID }))}},
MaxResults: aws.Int64(500),
IncludeDeprecated: lo.ToPtr(true),
}, func(page *ec2.DescribeImagesOutput, _ bool) bool {
for i := range page.Images {
for j := range res {
Expand Down

0 comments on commit bddb3d9

Please sign in to comment.