8000 Selectors are order-dependent? · Issue #1477 · roboll/helmfile · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Selectors are order-dependent? #1477
Closed
@mouchar

Description

@mouchar

Given a simple helmfile.yaml:

releases:
    - name: nolabel1
      namespace: kube-system
      chart: stable/nolabel
    - name: nolabel2
      namespace: default
      chart: stable/nolabel
    - name: foo
      namespace: kube-system
      chart: stable/foo
      labels:
        type: bar

When I want to select releases that don't have a label type equal to "bar" AND their name is not equal to "nolabel2", I would expect the only selected release would be the first one ("nolabel1").

However, the following selector returns both "nolabel1" and "nolabel2":

$ helmfile -l 'type!=bar,name!=nolabel2' list
NAME    	NAMESPACE  	ENABLED	LABELS                                           
nolabel1	kube-system	true   	chart:nolabel,name:nolabel1,namespace:kube-system
nolabel2	default    	true   	chart:nolabel,name:nolabel2,namespace:default    

To get things more confusing, when I swap both parts, it selects the expected release:

$ helmfile -l 'name!=nolabel2,type!=bar' list
NAME    	NAMESPACE  	ENABLED	LABELS                                           
nolabel1	kube-system	true   	chart:nolabel,name:nolabel1,namespace:kube-system

Edit:

$ helmfile version
helmfile version v0.128.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0