Update node-feature-discovery to v0.16.4 (#11250)

pull/11465/head
Mohamed Omar Zaian 2024-08-19 14:59:30 +02:00 committed by GitHub
parent 1093c76f9b
commit ad1ce92b41
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 482 additions and 123 deletions

View File

@ -193,7 +193,7 @@ Note: Upstart/SysV init based OS types are not supported.
- [gcp-pd-csi-plugin](https://github.com/kubernetes-sigs/gcp-compute-persistent-disk-csi-driver) v1.9.2 - [gcp-pd-csi-plugin](https://github.com/kubernetes-sigs/gcp-compute-persistent-disk-csi-driver) v1.9.2
- [local-path-provisioner](https://github.com/rancher/local-path-provisioner) v0.0.24 - [local-path-provisioner](https://github.com/rancher/local-path-provisioner) v0.0.24
- [local-volume-provisioner](https://github.com/kubernetes-sigs/sig-storage-local-static-provisioner) v2.5.0 - [local-volume-provisioner](https://github.com/kubernetes-sigs/sig-storage-local-static-provisioner) v2.5.0
- [node-feature-discovery](https://github.com/kubernetes-sigs/node-feature-discovery) v0.14.2 - [node-feature-discovery](https://github.com/kubernetes-sigs/node-feature-discovery) v0.16.4
## Container Runtime Notes ## Container Runtime Notes

View File

@ -3,7 +3,7 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition kind: CustomResourceDefinition
metadata: metadata:
annotations: annotations:
controller-gen.kubebuilder.io/version: v0.12.1 controller-gen.kubebuilder.io/version: v0.14.0
name: nodefeatures.nfd.k8s-sigs.io name: nodefeatures.nfd.k8s-sigs.io
spec: spec:
group: nfd.k8s-sigs.io group: nfd.k8s-sigs.io
@ -17,23 +17,30 @@ spec:
- name: v1alpha1 - name: v1alpha1
schema: schema:
openAPIV3Schema: openAPIV3Schema:
description: NodeFeature resource holds the features discovered for one node description: |-
in the cluster. NodeFeature resource holds the features discovered for one node in the
cluster.
properties: properties:
apiVersion: apiVersion:
description: 'APIVersion defines the versioned schema of this representation description: |-
of an object. Servers should convert recognized schemas to the latest APIVersion defines the versioned schema of this representation of an object.
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string type: string
kind: kind:
description: 'Kind is a string value representing the REST resource this description: |-
object represents. Servers may infer this from the endpoint the client Kind is a string value representing the REST resource this object represents.
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string type: string
metadata: metadata:
type: object type: object
spec: spec:
description: NodeFeatureSpec describes a NodeFeature object. description: Specification of the NodeFeature, containing features discovered
for a node.
properties: properties:
features: features:
description: Features is the full "raw" features data that has been description: Features is the full "raw" features data that has been
@ -47,6 +54,7 @@ spec:
elements: elements:
additionalProperties: additionalProperties:
type: string type: string
description: Individual features of the feature set.
type: object type: object
required: required:
- elements - elements
@ -64,6 +72,7 @@ spec:
description: Nil is a dummy empty struct for protobuf description: Nil is a dummy empty struct for protobuf
compatibility compatibility
type: object type: object
description: Individual features of the feature set.
type: object type: object
required: required:
- elements - elements
@ -77,6 +86,7 @@ spec:
which is an instance having multiple attributes. which is an instance having multiple attributes.
properties: properties:
elements: elements:
description: Individual features of the feature set.
items: items:
description: InstanceFeature represents one instance of description: InstanceFeature represents one instance of
a complex features, e.g. a device. a complex features, e.g. a device.
@ -84,6 +94,7 @@ spec:
attributes: attributes:
additionalProperties: additionalProperties:
type: string type: string
description: Attributes of the instance feature.
type: object type: object
required: required:
- attributes - attributes
@ -113,62 +124,50 @@ apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition kind: CustomResourceDefinition
metadata: metadata:
annotations: annotations:
controller-gen.kubebuilder.io/version: v0.12.1 controller-gen.kubebuilder.io/version: v0.14.0
name: nodefeaturerules.nfd.k8s-sigs.io name: nodefeaturegroups.nfd.k8s-sigs.io
spec: spec:
group: nfd.k8s-sigs.io group: nfd.k8s-sigs.io
names: names:
kind: NodeFeatureRule kind: NodeFeatureGroup
listKind: NodeFeatureRuleList listKind: NodeFeatureGroupList
plural: nodefeaturerules plural: nodefeaturegroups
shortNames: shortNames:
- nfr - nfg
singular: nodefeaturerule singular: nodefeaturegroup
scope: Cluster scope: Namespaced
versions: versions:
- name: v1alpha1 - name: v1alpha1
schema: schema:
openAPIV3Schema: openAPIV3Schema:
description: NodeFeatureRule resource specifies a configuration for feature-based description: NodeFeatureGroup resource holds Node pools by featureGroup
customization of node objects, such as node labeling.
properties: properties:
apiVersion: apiVersion:
description: 'APIVersion defines the versioned schema of this representation description: |-
of an object. Servers should convert recognized schemas to the latest APIVersion defines the versioned schema of this representation of an object.
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources' Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string type: string
kind: kind:
description: 'Kind is a string value representing the REST resource this description: |-
object represents. Servers may infer this from the endpoint the client Kind is a string value representing the REST resource this object represents.
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds' Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string type: string
metadata: metadata:
type: object type: object
spec: spec:
description: NodeFeatureRuleSpec describes a NodeFeatureRule. description: Spec defines the rules to be evaluated.
properties: properties:
rules: featureGroupRules:
description: Rules is a list of node customization rules. description: List of rules to evaluate to determine nodes that belong
in this group.
items: items:
description: Rule defines a rule for node customization such as description: GroupRule defines a rule for nodegroup filtering.
labeling.
properties: properties:
extendedResources:
additionalProperties:
type: string
description: ExtendedResources to create if the rule matches.
type: object
labels:
additionalProperties:
type: string
description: Labels to create if the rule matches.
type: object
labelsTemplate:
description: LabelsTemplate specifies a template to expand for
dynamically generating multiple labels. Data (after template
expansion) must be keys with an optional value (<key>[=<value>])
separated by newlines.
type: string
matchAny: matchAny:
description: MatchAny specifies a list of matchers one of which description: MatchAny specifies a list of matchers one of which
must match. must match.
@ -179,25 +178,21 @@ spec:
description: MatchFeatures specifies a set of matcher description: MatchFeatures specifies a set of matcher
terms all of which must match. terms all of which must match.
items: items:
description: FeatureMatcherTerm defines requirements description: |-
against one feature set. All requirements (specified FeatureMatcherTerm defines requirements against one feature set. All
as MatchExpressions) are evaluated against each element requirements (specified as MatchExpressions) are evaluated against each
in the feature set. element in the feature set.
properties: properties:
feature: feature:
description: Feature is the name of the feature
set to match against.
type: string type: string
matchExpressions: matchExpressions:
additionalProperties: additionalProperties:
description: "MatchExpression specifies an expression description: |-
to evaluate against a set of input values. It MatchExpression specifies an expression to evaluate against a set of input
contains an operator that is applied when matching values. It contains an operator that is applied when matching the input and
the input and an array of values that the operator an array of values that the operator evaluates the input against.
evaluates the input against. \n NB: CreateMatchExpression
or MustCreateMatchExpression() should be used
for creating new instances. \n NB: Validate()
must be called if Op or Value fields are modified
or if a new instance is created from scratch
without using the helper functions."
properties: properties:
op: op:
description: Op is the operator to be applied. description: Op is the operator to be applied.
@ -214,28 +209,56 @@ spec:
- IsFalse - IsFalse
type: string type: string
value: value:
description: Value is the list of values that description: |-
the operand evaluates the input against. Value is the list of values that the operand evaluates the input
Value should be empty if the operator is against. Value should be empty if the operator is Exists, DoesNotExist,
Exists, DoesNotExist, IsTrue or IsFalse. IsTrue or IsFalse. Value should contain exactly one element if the
Value should contain exactly one element operator is Gt or Lt and exactly two elements if the operator is GtLt.
if the operator is Gt or Lt and exactly In other cases Value should contain at least one element.
two elements if the operator is GtLt. In
other cases Value should contain at least
one element.
items: items:
type: string type: string
type: array type: array
required: required:
- op - op
type: object type: object
description: MatchExpressionSet contains a set of description: |-
MatchExpressions, each of which is evaluated against MatchExpressions is the set of per-element expressions evaluated. These
a set of input values. match against the value of the specified elements.
type: object
matchName:
description: |-
MatchName in an expression that is matched against the name of each
element in the feature set.
properties:
op:
description: Op is the operator to be applied.
enum:
- In
- NotIn
- InRegexp
- Exists
- DoesNotExist
- Gt
- Lt
- GtLt
- IsTrue
- IsFalse
type: string
value:
description: |-
Value is the list of values that the operand evaluates the input
against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly one element if the
operator is Gt or Lt and exactly two elements if the operator is GtLt.
In other cases Value should contain at least one element.
items:
type: string
type: array
required:
- op
type: object type: object
required: required:
- feature - feature
- matchExpressions
type: object type: object
type: array type: array
required: required:
@ -246,23 +269,21 @@ spec:
description: MatchFeatures specifies a set of matcher terms description: MatchFeatures specifies a set of matcher terms
all of which must match. all of which must match.
items: items:
description: FeatureMatcherTerm defines requirements against description: |-
one feature set. All requirements (specified as MatchExpressions) FeatureMatcherTerm defines requirements against one feature set. All
are evaluated against each element in the feature set. requirements (specified as MatchExpressions) are evaluated against each
element in the feature set.
properties: properties:
feature: feature:
description: Feature is the name of the feature set to
match against.
type: string type: string
matchExpressions: matchExpressions:
additionalProperties: additionalProperties:
description: "MatchExpression specifies an expression description: |-
to evaluate against a set of input values. It contains MatchExpression specifies an expression to evaluate against a set of input
an operator that is applied when matching the input values. It contains an operator that is applied when matching the input and
and an array of values that the operator evaluates an array of values that the operator evaluates the input against.
the input against. \n NB: CreateMatchExpression or
MustCreateMatchExpression() should be used for creating
new instances. \n NB: Validate() must be called if
Op or Value fields are modified or if a new instance
is created from scratch without using the helper functions."
properties: properties:
op: op:
description: Op is the operator to be applied. description: Op is the operator to be applied.
@ -279,25 +300,350 @@ spec:
- IsFalse - IsFalse
type: string type: string
value: value:
description: Value is the list of values that the description: |-
operand evaluates the input against. Value should Value is the list of values that the operand evaluates the input
be empty if the operator is Exists, DoesNotExist, against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly IsTrue or IsFalse. Value should contain exactly one element if the
one element if the operator is Gt or Lt and exactly operator is Gt or Lt and exactly two elements if the operator is GtLt.
two elements if the operator is GtLt. In other In other cases Value should contain at least one element.
cases Value should contain at least one element.
items: items:
type: string type: string
type: array type: array
required: required:
- op - op
type: object type: object
description: MatchExpressionSet contains a set of MatchExpressions, description: |-
each of which is evaluated against a set of input values. MatchExpressions is the set of per-element expressions evaluated. These
match against the value of the specified elements.
type: object
matchName:
description: |-
MatchName in an expression that is matched against the name of each
element in the feature set.
properties:
op:
description: Op is the operator to be applied.
enum:
- In
- NotIn
- InRegexp
- Exists
- DoesNotExist
- Gt
- Lt
- GtLt
- IsTrue
- IsFalse
type: string
value:
description: |-
Value is the list of values that the operand evaluates the input
against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly one element if the
operator is Gt or Lt and exactly two elements if the operator is GtLt.
In other cases Value should contain at least one element.
items:
type: string
type: array
required:
- op
type: object
required:
- feature
type: object
type: array
name:
description: Name of the rule.
type: string
required:
- name
type: object
type: array
required:
- featureGroupRules
type: object
status:
description: |-
Status of the NodeFeatureGroup after the most recent evaluation of the
specification.
properties:
nodes:
description: Nodes is a list of FeatureGroupNode in the cluster that
match the featureGroupRules
items:
properties:
name:
description: Name of the node.
type: string
required:
- name
type: object
type: array
x-kubernetes-list-map-keys:
- name
x-kubernetes-list-type: map
type: object
required:
- spec
type: object
served: true
storage: true
subresources:
status: {}
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.14.0
name: nodefeaturerules.nfd.k8s-sigs.io
spec:
group: nfd.k8s-sigs.io
names:
kind: NodeFeatureRule
listKind: NodeFeatureRuleList
plural: nodefeaturerules
shortNames:
- nfr
singular: nodefeaturerule
scope: Cluster
versions:
- name: v1alpha1
schema:
openAPIV3Schema:
description: |-
NodeFeatureRule resource specifies a configuration for feature-based
customization of node objects, such as node labeling.
properties:
apiVersion:
description: |-
APIVersion defines the versioned schema of this representation of an object.
Servers should convert recognized schemas to the latest internal value, and
may reject unrecognized values.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
type: string
kind:
description: |-
Kind is a string value representing the REST resource this object represents.
Servers may infer this from the endpoint the client submits requests to.
Cannot be updated.
In CamelCase.
More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
type: string
metadata:
type: object
spec:
description: Spec defines the rules to be evaluated.
properties:
rules:
description: Rules is a list of node customization rules.
items:
description: Rule defines a rule for node customization such as
labeling.
properties:
annotations:
additionalProperties:
type: string
description: Annotations to create if the rule matches.
type: object
extendedResources:
additionalProperties:
type: string
description: ExtendedResources to create if the rule matches.
type: object
labels:
additionalProperties:
type: string
description: Labels to create if the rule matches.
type: object
labelsTemplate:
description: |-
LabelsTemplate specifies a template to expand for dynamically generating
multiple labels. Data (after template expansion) must be keys with an
optional value (<key>[=<value>]) separated by newlines.
type: string
matchAny:
description: MatchAny specifies a list of matchers one of which
must match.
items:
description: MatchAnyElem specifies one sub-matcher of MatchAny.
properties:
matchFeatures:
description: MatchFeatures specifies a set of matcher
terms all of which must match.
items:
description: |-
FeatureMatcherTerm defines requirements against one feature set. All
requirements (specified as MatchExpressions) are evaluated against each
element in the feature set.
properties:
feature:
description: Feature is the name of the feature
set to match against.
type: string
matchExpressions:
additionalProperties:
description: |-
MatchExpression specifies an expression to evaluate against a set of input
values. It contains an operator that is applied when matching the input and
an array of values that the operator evaluates the input against.
properties:
op:
description: Op is the operator to be applied.
enum:
- In
- NotIn
- InRegexp
- Exists
- DoesNotExist
- Gt
- Lt
- GtLt
- IsTrue
- IsFalse
type: string
value:
description: |-
Value is the list of values that the operand evaluates the input
against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly one element if the
operator is Gt or Lt and exactly two elements if the operator is GtLt.
In other cases Value should contain at least one element.
items:
type: string
type: array
required:
- op
type: object
description: |-
MatchExpressions is the set of per-element expressions evaluated. These
match against the value of the specified elements.
type: object
matchName:
description: |-
MatchName in an expression that is matched against the name of each
element in the feature set.
properties:
op:
description: Op is the operator to be applied.
enum:
- In
- NotIn
- InRegexp
- Exists
- DoesNotExist
- Gt
- Lt
- GtLt
- IsTrue
- IsFalse
type: string
value:
description: |-
Value is the list of values that the operand evaluates the input
against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly one element if the
operator is Gt or Lt and exactly two elements if the operator is GtLt.
In other cases Value should contain at least one element.
items:
type: string
type: array
required:
- op
type: object
required:
- feature
type: object
type: array
required:
- matchFeatures
type: object
type: array
matchFeatures:
description: MatchFeatures specifies a set of matcher terms
all of which must match.
items:
description: |-
FeatureMatcherTerm defines requirements against one feature set. All
requirements (specified as MatchExpressions) are evaluated against each
element in the feature set.
properties:
feature:
description: Feature is the name of the feature set to
match against.
type: string
matchExpressions:
additionalProperties:
description: |-
MatchExpression specifies an expression to evaluate against a set of input
values. It contains an operator that is applied when matching the input and
an array of values that the operator evaluates the input against.
properties:
op:
description: Op is the operator to be applied.
enum:
- In
- NotIn
- InRegexp
- Exists
- DoesNotExist
- Gt
- Lt
- GtLt
- IsTrue
- IsFalse
type: string
value:
description: |-
Value is the list of values that the operand evaluates the input
against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly one element if the
operator is Gt or Lt and exactly two elements if the operator is GtLt.
In other cases Value should contain at least one element.
items:
type: string
type: array
required:
- op
type: object
description: |-
MatchExpressions is the set of per-element expressions evaluated. These
match against the value of the specified elements.
type: object
matchName:
description: |-
MatchName in an expression that is matched against the name of each
element in the feature set.
properties:
op:
description: Op is the operator to be applied.
enum:
- In
- NotIn
- InRegexp
- Exists
- DoesNotExist
- Gt
- Lt
- GtLt
- IsTrue
- IsFalse
type: string
value:
description: |-
Value is the list of values that the operand evaluates the input
against. Value should be empty if the operator is Exists, DoesNotExist,
IsTrue or IsFalse. Value should contain exactly one element if the
operator is Gt or Lt and exactly two elements if the operator is GtLt.
In other cases Value should contain at least one element.
items:
type: string
type: array
required:
- op
type: object type: object
required: required:
- feature - feature
- matchExpressions
type: object type: object
type: array type: array
name: name:
@ -306,21 +652,24 @@ spec:
taints: taints:
description: Taints to create if the rule matches. description: Taints to create if the rule matches.
items: items:
description: The node this Taint is attached to has the "effect" description: |-
on any pod that does not tolerate the Taint. The node this Taint is attached to has the "effect" on
any pod that does not tolerate the Taint.
properties: properties:
effect: effect:
description: Required. The effect of the taint on pods description: |-
that do not tolerate the taint. Valid effects are NoSchedule, Required. The effect of the taint on pods
PreferNoSchedule and NoExecute. that do not tolerate the taint.
Valid effects are NoSchedule, PreferNoSchedule and NoExecute.
type: string type: string
key: key:
description: Required. The taint key to be applied to description: Required. The taint key to be applied to
a node. a node.
type: string type: string
timeAdded: timeAdded:
description: TimeAdded represents the time at which the description: |-
taint was added. It is only written for NoExecute taints. TimeAdded represents the time at which the taint was added.
It is only written for NoExecute taints.
format: date-time format: date-time
type: string type: string
value: value:
@ -335,17 +684,17 @@ spec:
vars: vars:
additionalProperties: additionalProperties:
type: string type: string
description: Vars is the variables to store if the rule matches. description: |-
Variables do not directly inflict any changes in the node Vars is the variables to store if the rule matches. Variables do not
object. However, they can be referenced from other rules enabling directly inflict any changes in the node object. However, they can be
more complex rule hierarchies, without exposing intermediary referenced from other rules enabling more complex rule hierarchies,
output values as labels. without exposing intermediary output values as labels.
type: object type: object
varsTemplate: varsTemplate:
description: VarsTemplate specifies a template to expand for description: |-
dynamically generating multiple variables. Data (after template VarsTemplate specifies a template to expand for dynamically generating
expansion) must be keys with an optional value (<key>[=<value>]) multiple variables. Data (after template expansion) must be keys with an
separated by newlines. optional value (<key>[=<value>]) separated by newlines.
type: string type: string
required: required:
- name - name

View File

@ -18,10 +18,18 @@ rules:
resources: resources:
- nodefeatures - nodefeatures
- nodefeaturerules - nodefeaturerules
- nodefeaturegroups
verbs: verbs:
- get - get
- list - list
- watch - watch
- apiGroups:
- nfd.k8s-sigs.io
resources:
- nodefeaturegroup/status
verbs:
- patch
- update
- apiGroups: - apiGroups:
- coordination.k8s.io - coordination.k8s.io
resources: resources:

View File

@ -33,22 +33,18 @@ spec:
image: {{ node_feature_discovery_image_repo }}:{{ node_feature_discovery_image_tag }} image: {{ node_feature_discovery_image_repo }}:{{ node_feature_discovery_image_tag }}
imagePullPolicy: IfNotPresent imagePullPolicy: IfNotPresent
livenessProbe: livenessProbe:
exec: grpc:
command: port: 8082
- "/usr/bin/grpc_health_probe"
- "-addr=:8080"
initialDelaySeconds: 10 initialDelaySeconds: 10
periodSeconds: 10 periodSeconds: 10
readinessProbe: readinessProbe:
exec: grpc:
command: port: 8082
- "/usr/bin/grpc_health_probe"
- "-addr=:8080"
initialDelaySeconds: 5 initialDelaySeconds: 5
periodSeconds: 10 periodSeconds: 10
failureThreshold: 10 failureThreshold: 10
ports: ports:
- containerPort: 8080 - containerPort: 8082
name: grpc name: grpc
- containerPort: 8081 - containerPort: 8081
name: metrics name: metrics

View File

@ -12,3 +12,9 @@ rules:
- create - create
- get - get
- update - update
- apiGroups:
- ""
resources:
- pods
verbs:
- get

View File

@ -409,7 +409,7 @@ metallb_speaker_image_repo: "{{ quay_image_repo }}/metallb/speaker"
metallb_controller_image_repo: "{{ quay_image_repo }}/metallb/controller" metallb_controller_image_repo: "{{ quay_image_repo }}/metallb/controller"
metallb_version: v0.13.9 metallb_version: v0.13.9
node_feature_discovery_version: v0.14.2 node_feature_discovery_version: v0.16.4
node_feature_discovery_image_repo: "{{ kube_image_repo }}/nfd/node-feature-discovery" node_feature_discovery_image_repo: "{{ kube_image_repo }}/nfd/node-feature-discovery"
node_feature_discovery_image_tag: "{{ node_feature_discovery_version }}" node_feature_discovery_image_tag: "{{ node_feature_discovery_version }}"