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

NodeFeatureRule: dynamic values for labels #1192

Closed
marquiz opened this issue Apr 25, 2023 · 1 comment · Fixed by #1226
Closed

NodeFeatureRule: dynamic values for labels #1192

marquiz opened this issue Apr 25, 2023 · 1 comment · Fixed by #1226
Assignees
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@marquiz
Copy link
Contributor

marquiz commented Apr 25, 2023

What would you like to be added:

For extended resources (extendedResources field in NodeFeatureRule) we have a handy @ notation for dynamically setting the value (capacity) of an extended resource. It would be nice to support this for labels, too. That is, having something like (just a random example):

spec:
  rules:
    - name: "my dynamic label value rule"
      labels:
        linux-lsm-enabled: "@kernel.config.LSM"

Which would then create label like feature.node.kubernetes.io/lsm-enabled=apparmor

This can be already achieved with templating but it's rather cumbersome for something simple like this.

Why is this needed:

More flexible labeling. Avoid using templates for simple cases of dynamic label values.

@marquiz marquiz added the kind/feature Categorizes issue or PR as related to a new feature. label Apr 25, 2023
@AhmedGrati
Copy link

/assign

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants