Skip to content

filter non-ASG nodes by tag  #654

@universam1

Description

@universam1

Describe the feature

Karpenter nodes are not bound to a Autoscaling Group. Filter on tags via check-asg-tag-before-draining is scoped to ASG only, so it is not possible to filter nodes such nodes based on tags.

if m.CheckIfManaged {
if nodeInfo.AsgName == "" {
// If ASG tags are not propagated we might need to use the API
// to retrieve the ASG name
nodeInfo.AsgName, err = m.retrieveAutoScalingGroupName(nodeInfo.InstanceID)
if err != nil {
return nil, fmt.Errorf("unable to retrieve AutoScaling group: %w", err)
}
}
if nodeInfo.Tags[m.ManagedAsgTag] == "" {

Is the feature request related to a problem?

AFAIK pre - filtering the Spot ITN Events is not possible because EC2 Spot Instance Interruption Warning do not contain tags of the instance where we could filter the rule on

I have several clusters in one account and thus I am missing an option in NTH to filter for cluster respective nodes only.

Describe alternatives you've considered

none

Metadata

Metadata

Assignees

Labels

Priority: CriticalThis issue will be seen by all usersType: BugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions