Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: AWSNodeTemplate controller should not produce an error if no securityGroupSelector is specified #3437

Merged
merged 6 commits into from
Feb 22, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion pkg/providers/securitygroup/securitygroup.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,11 @@ func (p *Provider) List(ctx context.Context, nodeTemplate *v1alpha1.AWSNodeTempl
p.Lock()
defer p.Unlock()
// Get SecurityGroups
securityGroups, err := p.getSecurityGroups(ctx, p.getFilters(nodeTemplate))
filters := p.getFilters(nodeTemplate)
engedaam marked this conversation as resolved.
Show resolved Hide resolved
if len(filters) == 0 {
engedaam marked this conversation as resolved.
Show resolved Hide resolved
return []string{}, nil
}
securityGroups, err := p.getSecurityGroups(ctx, filters)
if err != nil {
return nil, err
}
Expand Down