v1alpha1

package
v0.15.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 5, 2024 License: Apache-2.0 Imports: 13 Imported by: 1

Documentation

Overview

Package v1alpha1 is the v1alpha1 version of the nfd API. +k8s:deepcopy-gen=package +kubebuilder:object:generate=true +groupName=nfd.k8s-sigs.io

Index

Constants

View Source
const (
	// FeatureLabelNs is the (default) namespace for feature labels.
	FeatureLabelNs = "feature.node.kubernetes.io"

	// FeatureLabelSubNsSuffix is the suffix for allowed feature label sub-namespaces.
	FeatureLabelSubNsSuffix = "." + FeatureLabelNs

	// ProfileLabelNs is the namespace for profile labels.
	ProfileLabelNs = "profile.node.kubernetes.io"

	// ProfileLabelSubNsSuffix is the suffix for allowed profile label sub-namespaces.
	ProfileLabelSubNsSuffix = "." + ProfileLabelNs

	// TaintNs is the k8s.io namespace that can be used for NFD-managed taints.
	TaintNs = "feature.node.kubernetes.io"

	// TaintSubNsSuffix is the suffix for allowed sub-namespaces for NFD-managed taints.
	TaintSubNsSuffix = "." + TaintNs

	// AnnotationNs namespace for all NFD-related annotations.
	AnnotationNs = "nfd.node.kubernetes.io"

	// ExtendedResourceNs is the namespace for extended resources.
	ExtendedResourceNs = "feature.node.kubernetes.io"

	// ExtendedResourceSubNsSuffix is the suffix for allowed extended resources sub-namespaces.
	ExtendedResourceSubNsSuffix = "." + ExtendedResourceNs

	// ExtendedResourceAnnotation is the annotation that holds all extended resources managed by NFD.
	ExtendedResourceAnnotation = AnnotationNs + "/extended-resources"

	// FeatureLabelsAnnotation is the annotation that holds all feature labels managed by NFD.
	FeatureLabelsAnnotation = AnnotationNs + "/feature-labels"

	// MasterVersionAnnotation is the annotation that holds the version of nfd-master running on the node
	// DEPRECATED: will not be used in NFD v0.15 or later.
	MasterVersionAnnotation = AnnotationNs + "/master.version"

	// WorkerVersionAnnotation is the annotation that holds the version of nfd-worker running on the node
	WorkerVersionAnnotation = AnnotationNs + "/worker.version"

	// NodeTaintsAnnotation is the annotation that holds the taints that nfd-master set on the node
	NodeTaintsAnnotation = AnnotationNs + "/taints"

	// FeatureAnnotationsTrackingAnnotation is the annotation that holds all feature annotations that nfd-master set on the node
	FeatureAnnotationsTrackingAnnotation = AnnotationNs + "/feature-annotations"

	// NodeFeatureObjNodeNameLabel is the label that specifies which node the
	// NodeFeature object is targeting. Creators of NodeFeature objects must
	// set this label and consumers of the objects are supposed to use the
	// label for filtering features designated for a certain node.
	NodeFeatureObjNodeNameLabel = "nfd.node.kubernetes.io/node-name"

	// FeatureAnnotationNs is the (default) namespace for feature annotations.
	FeatureAnnotationNs = "feature.node.kubernetes.io"

	// FeatureAnnotationSubNsSuffix is the suffix for allowed feature annotation sub-namespaces.
	FeatureAnnotationSubNsSuffix = "." + FeatureAnnotationNs
)
View Source
const (
	// RuleBackrefDomain is the special feature domain for backreferencing
	// output of preceding rules.
	RuleBackrefDomain = "rule"
	// RuleBackrefFeature is the special feature name for backreferencing
	// output of preceding rules.
	RuleBackrefFeature = "matched"
)
View Source
const MatchAllNames = "*"

MatchAllNames is a special key in MatchExpressionSet to use field names (keys from the input) instead of values when matching.

Variables

View Source
var (
	ErrInvalidLengthGenerated        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowGenerated          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupGenerated = fmt.Errorf("proto: unexpected end of group")
)
View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: "nfd.k8s-sigs.io", Version: "v1alpha1"}

	// SchemeBuilder is the scheme builder for this API.
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)

	// AddToScheme is a function to register this API group and version to a scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource name and returns a Group qualified GroupResource.

Types

type AttributeFeatureSet added in v0.12.0

type AttributeFeatureSet struct {
	Elements map[string]string `json:"elements" protobuf:"bytes,1,rep,name=elements"`
}

AttributeFeatureSet is a set of features having string value.

+protobuf=true

func NewAttributeFeatures added in v0.12.0

func NewAttributeFeatures(values map[string]string) AttributeFeatureSet

NewAttributeFeatures creates a new instance of ValueFeatureSet.

func (*AttributeFeatureSet) DeepCopy added in v0.12.0

func (in *AttributeFeatureSet) DeepCopy() *AttributeFeatureSet

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new AttributeFeatureSet.

func (*AttributeFeatureSet) DeepCopyInto added in v0.12.0

func (in *AttributeFeatureSet) DeepCopyInto(out *AttributeFeatureSet)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*AttributeFeatureSet) Descriptor added in v0.12.0

func (*AttributeFeatureSet) Descriptor() ([]byte, []int)

func (*AttributeFeatureSet) Marshal added in v0.12.0

func (m *AttributeFeatureSet) Marshal() (dAtA []byte, err error)

func (*AttributeFeatureSet) MarshalTo added in v0.12.0

func (m *AttributeFeatureSet) MarshalTo(dAtA []byte) (int, error)

func (*AttributeFeatureSet) MarshalToSizedBuffer added in v0.12.0

func (m *AttributeFeatureSet) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*AttributeFeatureSet) MergeInto added in v0.12.0

func (in *AttributeFeatureSet) MergeInto(out *AttributeFeatureSet)

MergeInto merges two sets of attribute featues.

func (*AttributeFeatureSet) ProtoMessage added in v0.12.0

func (*AttributeFeatureSet) ProtoMessage()

func (*AttributeFeatureSet) Reset added in v0.12.0

func (m *AttributeFeatureSet) Reset()

func (*AttributeFeatureSet) Size added in v0.12.0

func (m *AttributeFeatureSet) Size() (n int)

func (*AttributeFeatureSet) String added in v0.12.0

func (this *AttributeFeatureSet) String() string

func (*AttributeFeatureSet) Unmarshal added in v0.12.0

func (m *AttributeFeatureSet) Unmarshal(dAtA []byte) error

func (*AttributeFeatureSet) XXX_DiscardUnknown added in v0.12.0

func (m *AttributeFeatureSet) XXX_DiscardUnknown()

func (*AttributeFeatureSet) XXX_Marshal added in v0.12.0

func (m *AttributeFeatureSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AttributeFeatureSet) XXX_Merge added in v0.12.0

func (m *AttributeFeatureSet) XXX_Merge(src proto.Message)

func (*AttributeFeatureSet) XXX_Size added in v0.12.0

func (m *AttributeFeatureSet) XXX_Size() int

func (*AttributeFeatureSet) XXX_Unmarshal added in v0.12.0

func (m *AttributeFeatureSet) XXX_Unmarshal(b []byte) error

type FeatureMatcher

type FeatureMatcher []FeatureMatcherTerm

FeatureMatcher specifies a set of feature matcher terms (i.e. per-feature matchers), all of which must match.

func (FeatureMatcher) DeepCopy

func (in FeatureMatcher) DeepCopy() FeatureMatcher

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureMatcher.

func (FeatureMatcher) DeepCopyInto

func (in FeatureMatcher) DeepCopyInto(out *FeatureMatcher)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FeatureMatcherTerm

type FeatureMatcherTerm struct {
	// Feature is the name of the feature set to match against.
	Feature string `json:"feature"`
	// MatchExpressions is the set of per-element expressions evaluated. These
	// match against the value of the specified elements.
	// +optional
	MatchExpressions *MatchExpressionSet `json:"matchExpressions"`
	// MatchName in an expression that is matched against the name of each
	// element in the feature set.
	// +optional
	MatchName *MatchExpression `json:"matchName"`
}

FeatureMatcherTerm defines requirements against one feature set. All requirements (specified as MatchExpressions) are evaluated against each element in the feature set.

func (*FeatureMatcherTerm) DeepCopy

func (in *FeatureMatcherTerm) DeepCopy() *FeatureMatcherTerm

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureMatcherTerm.

func (*FeatureMatcherTerm) DeepCopyInto

func (in *FeatureMatcherTerm) DeepCopyInto(out *FeatureMatcherTerm)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Features added in v0.12.0

type Features struct {
	// Flags contains all the flag-type features of the node.
	// +optional
	Flags map[string]FlagFeatureSet `json:"flags" protobuf:"bytes,1,rep,name=flags"`
	// Attributes contains all the attribute-type features of the node.
	// +optional
	Attributes map[string]AttributeFeatureSet `json:"attributes" protobuf:"bytes,2,rep,name=vattributes"`
	// Instances contains all the instance-type features of the node.
	// +optional
	Instances map[string]InstanceFeatureSet `json:"instances" protobuf:"bytes,3,rep,name=instances"`
}

Features is the collection of all discovered features.

+protobuf=true

func NewFeatures added in v0.12.0

func NewFeatures() *Features

NewFeatures creates a new instance of Features, initializing all feature types (flags, attributes and instances) to empty values.

func (*Features) DeepCopy added in v0.12.0

func (in *Features) DeepCopy() *Features

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Features.

func (*Features) DeepCopyInto added in v0.12.0

func (in *Features) DeepCopyInto(out *Features)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Features) Descriptor added in v0.12.0

func (*Features) Descriptor() ([]byte, []int)

func (*Features) Exists added in v0.12.0

func (f *Features) Exists(name string) string

Exists returns a non-empty string if a feature exists. The return value is the type of the feautre, i.e. "flag", "attribute" or "instance".

func (*Features) InsertAttributeFeatures added in v0.12.0

func (f *Features) InsertAttributeFeatures(domain, feature string, values map[string]string)

InsertAttributeFeatures inserts new values into a specific feature.

func (*Features) Marshal added in v0.12.0

func (m *Features) Marshal() (dAtA []byte, err error)

func (*Features) MarshalTo added in v0.12.0

func (m *Features) MarshalTo(dAtA []byte) (int, error)

func (*Features) MarshalToSizedBuffer added in v0.12.0

func (m *Features) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Features) MergeInto added in v0.12.0

func (in *Features) MergeInto(out *Features)

MergeInto merges two sets of features into one. Features from the input set take precedence (overwrite) features from the existing features of the set we're merging into.

func (*Features) ProtoMessage added in v0.12.0

func (*Features) ProtoMessage()

func (*Features) Reset added in v0.12.0

func (m *Features) Reset()

func (*Features) Size added in v0.12.0

func (m *Features) Size() (n int)

func (*Features) String added in v0.12.0

func (this *Features) String() string

func (*Features) Unmarshal added in v0.12.0

func (m *Features) Unmarshal(dAtA []byte) error

func (*Features) XXX_DiscardUnknown added in v0.12.0

func (m *Features) XXX_DiscardUnknown()

func (*Features) XXX_Marshal added in v0.12.0

func (m *Features) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Features) XXX_Merge added in v0.12.0

func (m *Features) XXX_Merge(src proto.Message)

func (*Features) XXX_Size added in v0.12.0

func (m *Features) XXX_Size() int

func (*Features) XXX_Unmarshal added in v0.12.0

func (m *Features) XXX_Unmarshal(b []byte) error

type FlagFeatureSet added in v0.12.0

type FlagFeatureSet struct {
	Elements map[string]Nil `json:"elements" protobuf:"bytes,1,rep,name=elements"`
}

FlagFeatureSet is a set of simple features only containing names without values.

+protobuf=true

func NewFlagFeatures added in v0.12.0

func NewFlagFeatures(keys ...string) FlagFeatureSet

NewFlagFeatures creates a new instance of KeyFeatureSet.

func (*FlagFeatureSet) DeepCopy added in v0.12.0

func (in *FlagFeatureSet) DeepCopy() *FlagFeatureSet

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FlagFeatureSet.

func (*FlagFeatureSet) DeepCopyInto added in v0.12.0

func (in *FlagFeatureSet) DeepCopyInto(out *FlagFeatureSet)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FlagFeatureSet) Descriptor added in v0.12.0

func (*FlagFeatureSet) Descriptor() ([]byte, []int)

func (*FlagFeatureSet) Marshal added in v0.12.0

func (m *FlagFeatureSet) Marshal() (dAtA []byte, err error)

func (*FlagFeatureSet) MarshalTo added in v0.12.0

func (m *FlagFeatureSet) MarshalTo(dAtA []byte) (int, error)

func (*FlagFeatureSet) MarshalToSizedBuffer added in v0.12.0

func (m *FlagFeatureSet) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*FlagFeatureSet) MergeInto added in v0.12.0

func (in *FlagFeatureSet) MergeInto(out *FlagFeatureSet)

MergeInto merges two sets of flag featues.

func (*FlagFeatureSet) ProtoMessage added in v0.12.0

func (*FlagFeatureSet) ProtoMessage()

func (*FlagFeatureSet) Reset added in v0.12.0

func (m *FlagFeatureSet) Reset()

func (*FlagFeatureSet) Size added in v0.12.0

func (m *FlagFeatureSet) Size() (n int)

func (*FlagFeatureSet) String added in v0.12.0

func (this *FlagFeatureSet) String() string

func (*FlagFeatureSet) Unmarshal added in v0.12.0

func (m *FlagFeatureSet) Unmarshal(dAtA []byte) error

func (*FlagFeatureSet) XXX_DiscardUnknown added in v0.12.0

func (m *FlagFeatureSet) XXX_DiscardUnknown()

func (*FlagFeatureSet) XXX_Marshal added in v0.12.0

func (m *FlagFeatureSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*FlagFeatureSet) XXX_Merge added in v0.12.0

func (m *FlagFeatureSet) XXX_Merge(src proto.Message)

func (*FlagFeatureSet) XXX_Size added in v0.12.0

func (m *FlagFeatureSet) XXX_Size() int

func (*FlagFeatureSet) XXX_Unmarshal added in v0.12.0

func (m *FlagFeatureSet) XXX_Unmarshal(b []byte) error

type InstanceFeature added in v0.12.0

type InstanceFeature struct {
	Attributes map[string]string `json:"attributes" protobuf:"bytes,1,rep,name=attributes"`
}

InstanceFeature represents one instance of a complex features, e.g. a device.

+protobuf=true

func NewInstanceFeature added in v0.12.0

func NewInstanceFeature(attrs map[string]string) *InstanceFeature

NewInstanceFeature creates a new InstanceFeature instance.

func (*InstanceFeature) DeepCopy added in v0.12.0

func (in *InstanceFeature) DeepCopy() *InstanceFeature

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InstanceFeature.

func (*InstanceFeature) DeepCopyInto added in v0.12.0

func (in *InstanceFeature) DeepCopyInto(out *InstanceFeature)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*InstanceFeature) Descriptor added in v0.12.0

func (*InstanceFeature) Descriptor() ([]byte, []int)

func (*InstanceFeature) Marshal added in v0.12.0

func (m *InstanceFeature) Marshal() (dAtA []byte, err error)

func (*InstanceFeature) MarshalTo added in v0.12.0

func (m *InstanceFeature) MarshalTo(dAtA []byte) (int, error)

func (*InstanceFeature) MarshalToSizedBuffer added in v0.12.0

func (m *InstanceFeature) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*InstanceFeature) ProtoMessage added in v0.12.0

func (*InstanceFeature) ProtoMessage()

func (*InstanceFeature) Reset added in v0.12.0

func (m *InstanceFeature) Reset()

func (*InstanceFeature) Size added in v0.12.0

func (m *InstanceFeature) Size() (n int)

func (*InstanceFeature) String added in v0.12.0

func (this *InstanceFeature) String() string

func (*InstanceFeature) Unmarshal added in v0.12.0

func (m *InstanceFeature) Unmarshal(dAtA []byte) error

func (*InstanceFeature) XXX_DiscardUnknown added in v0.12.0

func (m *InstanceFeature) XXX_DiscardUnknown()

func (*InstanceFeature) XXX_Marshal added in v0.12.0

func (m *InstanceFeature) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstanceFeature) XXX_Merge added in v0.12.0

func (m *InstanceFeature) XXX_Merge(src proto.Message)

func (*InstanceFeature) XXX_Size added in v0.12.0

func (m *InstanceFeature) XXX_Size() int

func (*InstanceFeature) XXX_Unmarshal added in v0.12.0

func (m *InstanceFeature) XXX_Unmarshal(b []byte) error

type InstanceFeatureSet added in v0.12.0

type InstanceFeatureSet struct {
	Elements []InstanceFeature `json:"elements" protobuf:"bytes,1,rep,name=elements"`
}

InstanceFeatureSet is a set of features each of which is an instance having multiple attributes.

+protobuf=true

func NewInstanceFeatures added in v0.12.0

func NewInstanceFeatures(instances []InstanceFeature) InstanceFeatureSet

NewInstanceFeatures creates a new instance of InstanceFeatureSet.

func (*InstanceFeatureSet) DeepCopy added in v0.12.0

func (in *InstanceFeatureSet) DeepCopy() *InstanceFeatureSet

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new InstanceFeatureSet.

func (*InstanceFeatureSet) DeepCopyInto added in v0.12.0

func (in *InstanceFeatureSet) DeepCopyInto(out *InstanceFeatureSet)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*InstanceFeatureSet) Descriptor added in v0.12.0

func (*InstanceFeatureSet) Descriptor() ([]byte, []int)

func (*InstanceFeatureSet) Marshal added in v0.12.0

func (m *InstanceFeatureSet) Marshal() (dAtA []byte, err error)

func (*InstanceFeatureSet) MarshalTo added in v0.12.0

func (m *InstanceFeatureSet) MarshalTo(dAtA []byte) (int, error)

func (*InstanceFeatureSet) MarshalToSizedBuffer added in v0.12.0

func (m *InstanceFeatureSet) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*InstanceFeatureSet) MergeInto added in v0.12.0

func (in *InstanceFeatureSet) MergeInto(out *InstanceFeatureSet)

MergeInto merges two sets of instance featues.

func (*InstanceFeatureSet) ProtoMessage added in v0.12.0

func (*InstanceFeatureSet) ProtoMessage()

func (*InstanceFeatureSet) Reset added in v0.12.0

func (m *InstanceFeatureSet) Reset()

func (*InstanceFeatureSet) Size added in v0.12.0

func (m *InstanceFeatureSet) Size() (n int)

func (*InstanceFeatureSet) String added in v0.12.0

func (this *InstanceFeatureSet) String() string

func (*InstanceFeatureSet) Unmarshal added in v0.12.0

func (m *InstanceFeatureSet) Unmarshal(dAtA []byte) error

func (*InstanceFeatureSet) XXX_DiscardUnknown added in v0.12.0

func (m *InstanceFeatureSet) XXX_DiscardUnknown()

func (*InstanceFeatureSet) XXX_Marshal added in v0.12.0

func (m *InstanceFeatureSet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstanceFeatureSet) XXX_Merge added in v0.12.0

func (m *InstanceFeatureSet) XXX_Merge(src proto.Message)

func (*InstanceFeatureSet) XXX_Size added in v0.12.0

func (m *InstanceFeatureSet) XXX_Size() int

func (*InstanceFeatureSet) XXX_Unmarshal added in v0.12.0

func (m *InstanceFeatureSet) XXX_Unmarshal(b []byte) error

type MatchAnyElem

type MatchAnyElem struct {
	// MatchFeatures specifies a set of matcher terms all of which must match.
	MatchFeatures FeatureMatcher `json:"matchFeatures"`
}

MatchAnyElem specifies one sub-matcher of MatchAny.

func (*MatchAnyElem) DeepCopy

func (in *MatchAnyElem) DeepCopy() *MatchAnyElem

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MatchAnyElem.

func (*MatchAnyElem) DeepCopyInto

func (in *MatchAnyElem) DeepCopyInto(out *MatchAnyElem)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MatchExpression

type MatchExpression struct {
	// Op is the operator to be applied.
	Op MatchOp `json:"op"`

	// 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.
	// +optional
	Value MatchValue `json:"value,omitempty"`
}

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.

func (*MatchExpression) DeepCopy

func (in *MatchExpression) DeepCopy() *MatchExpression

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MatchExpression.

func (*MatchExpression) DeepCopyInto

func (in *MatchExpression) DeepCopyInto(out *MatchExpression)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MatchExpressionSet

type MatchExpressionSet map[string]*MatchExpression

MatchExpressionSet contains a set of MatchExpressions, each of which is evaluated against a set of input values.

func (MatchExpressionSet) DeepCopy

func (in MatchExpressionSet) DeepCopy() MatchExpressionSet

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MatchExpressionSet.

func (MatchExpressionSet) DeepCopyInto

func (in MatchExpressionSet) DeepCopyInto(out *MatchExpressionSet)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type MatchOp

type MatchOp string

MatchOp is the match operator that is applied on values when evaluating a MatchExpression. +kubebuilder:validation:Enum="In";"NotIn";"InRegexp";"Exists";"DoesNotExist";"Gt";"Lt";"GtLt";"IsTrue";"IsFalse"

const (
	// MatchAny returns always true.
	MatchAny MatchOp = ""
	// MatchIn returns true if any of the values stored in the expression is
	// equal to the input.
	MatchIn MatchOp = "In"
	// MatchNotIn returns true if none of the values in the expression are
	// equal to the input.
	MatchNotIn MatchOp = "NotIn"
	// MatchInRegexp treats values of the expression as regular expressions and
	// returns true if any of them matches the input.
	MatchInRegexp MatchOp = "InRegexp"
	// MatchExists returns true if the input is valid. The expression must not
	// have any values.
	MatchExists MatchOp = "Exists"
	// MatchDoesNotExist returns true if the input is not valid. The expression
	// must not have any values.
	MatchDoesNotExist MatchOp = "DoesNotExist"
	// MatchGt returns true if the input is greater than the value of the
	// expression (number of values in the expression must be exactly one).
	// Both the input and value must be integer numbers, otherwise an error is
	// returned.
	MatchGt MatchOp = "Gt"
	// MatchLt returns true if the input is less  than the value of the
	// expression (number of values in the expression must be exactly one).
	// Both the input and value must be integer numbers, otherwise an error is
	// returned.
	MatchLt MatchOp = "Lt"
	// MatchGtLt returns true if the input is between two values, i.e. greater
	// than the first value and less than the second value of the expression
	// (number of values in the expression must be exactly two). Both the input
	// and values must be integer numbers, otherwise an error is returned.
	MatchGtLt MatchOp = "GtLt"
	// MatchIsTrue returns true if the input holds the value "true". The
	// expression must not have any values.
	MatchIsTrue MatchOp = "IsTrue"
	// MatchIsFalse returns true if the input holds the value "false". The
	// expression must not have any values.
	MatchIsFalse MatchOp = "IsFalse"
)

type MatchValue

type MatchValue []string

MatchValue is the list of values associated with a MatchExpression.

func (MatchValue) DeepCopy

func (in MatchValue) DeepCopy() MatchValue

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new MatchValue.

func (MatchValue) DeepCopyInto

func (in MatchValue) DeepCopyInto(out *MatchValue)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Nil added in v0.12.0

type Nil struct{}

Nil is a dummy empty struct for protobuf compatibility

+protobuf=true

func (*Nil) DeepCopy added in v0.12.0

func (in *Nil) DeepCopy() *Nil

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Nil.

func (*Nil) DeepCopyInto added in v0.12.0

func (in *Nil) DeepCopyInto(out *Nil)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Nil) Descriptor added in v0.12.0

func (*Nil) Descriptor() ([]byte, []int)

func (*Nil) Marshal added in v0.12.0

func (m *Nil) Marshal() (dAtA []byte, err error)

func (*Nil) MarshalTo added in v0.12.0

func (m *Nil) MarshalTo(dAtA []byte) (int, error)

func (*Nil) MarshalToSizedBuffer added in v0.12.0

func (m *Nil) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*Nil) ProtoMessage added in v0.12.0

func (*Nil) ProtoMessage()

func (*Nil) Reset added in v0.12.0

func (m *Nil) Reset()

func (*Nil) Size added in v0.12.0

func (m *Nil) Size() (n int)

func (*Nil) String added in v0.12.0

func (this *Nil) String() string

func (*Nil) Unmarshal added in v0.12.0

func (m *Nil) Unmarshal(dAtA []byte) error

func (*Nil) XXX_DiscardUnknown added in v0.12.0

func (m *Nil) XXX_DiscardUnknown()

func (*Nil) XXX_Marshal added in v0.12.0

func (m *Nil) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Nil) XXX_Merge added in v0.12.0

func (m *Nil) XXX_Merge(src proto.Message)

func (*Nil) XXX_Size added in v0.12.0

func (m *Nil) XXX_Size() int

func (*Nil) XXX_Unmarshal added in v0.12.0

func (m *Nil) XXX_Unmarshal(b []byte) error

type NodeFeature added in v0.12.0

type NodeFeature struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec NodeFeatureSpec `json:"spec"`
}

NodeFeature resource holds the features discovered for one node in the cluster. +kubebuilder:object:root=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +genclient

func (*NodeFeature) DeepCopy added in v0.12.0

func (in *NodeFeature) DeepCopy() *NodeFeature

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeFeature.

func (*NodeFeature) DeepCopyInto added in v0.12.0

func (in *NodeFeature) DeepCopyInto(out *NodeFeature)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NodeFeature) DeepCopyObject added in v0.12.0

func (in *NodeFeature) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NodeFeatureList added in v0.12.0

type NodeFeatureList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []NodeFeature `json:"items"`
}

NodeFeatureList contains a list of NodeFeature objects. +kubebuilder:object:root=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*NodeFeatureList) DeepCopy added in v0.12.0

func (in *NodeFeatureList) DeepCopy() *NodeFeatureList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeFeatureList.

func (*NodeFeatureList) DeepCopyInto added in v0.12.0

func (in *NodeFeatureList) DeepCopyInto(out *NodeFeatureList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NodeFeatureList) DeepCopyObject added in v0.12.0

func (in *NodeFeatureList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NodeFeatureRule

type NodeFeatureRule struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec NodeFeatureRuleSpec `json:"spec"`
}

NodeFeatureRule resource specifies a configuration for feature-based customization of node objects, such as node labeling. +kubebuilder:object:root=true +kubebuilder:resource:scope=Cluster,shortName=nfr +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +genclient +genclient:nonNamespaced

func (*NodeFeatureRule) DeepCopy

func (in *NodeFeatureRule) DeepCopy() *NodeFeatureRule

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeFeatureRule.

func (*NodeFeatureRule) DeepCopyInto

func (in *NodeFeatureRule) DeepCopyInto(out *NodeFeatureRule)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NodeFeatureRule) DeepCopyObject

func (in *NodeFeatureRule) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NodeFeatureRuleList

type NodeFeatureRuleList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata"`

	Items []NodeFeatureRule `json:"items"`
}

NodeFeatureRuleList contains a list of NodeFeatureRule objects. +kubebuilder:object:root=true +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*NodeFeatureRuleList) DeepCopy

func (in *NodeFeatureRuleList) DeepCopy() *NodeFeatureRuleList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeFeatureRuleList.

func (*NodeFeatureRuleList) DeepCopyInto

func (in *NodeFeatureRuleList) DeepCopyInto(out *NodeFeatureRuleList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NodeFeatureRuleList) DeepCopyObject

func (in *NodeFeatureRuleList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type NodeFeatureRuleSpec

type NodeFeatureRuleSpec struct {
	// Rules is a list of node customization rules.
	Rules []Rule `json:"rules"`
}

NodeFeatureRuleSpec describes a NodeFeatureRule.

func (*NodeFeatureRuleSpec) DeepCopy

func (in *NodeFeatureRuleSpec) DeepCopy() *NodeFeatureRuleSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeFeatureRuleSpec.

func (*NodeFeatureRuleSpec) DeepCopyInto

func (in *NodeFeatureRuleSpec) DeepCopyInto(out *NodeFeatureRuleSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NodeFeatureSpec added in v0.12.0

type NodeFeatureSpec struct {
	// Features is the full "raw" features data that has been discovered.
	// +optional
	Features Features `json:"features"`
	// Labels is the set of node labels that are requested to be created.
	// +optional
	Labels map[string]string `json:"labels"`
}

NodeFeatureSpec describes a NodeFeature object.

func NewNodeFeatureSpec added in v0.12.4

func NewNodeFeatureSpec() *NodeFeatureSpec

NewNodeFeatureSpec creates a new emprty instance of NodeFeatureSpec type, initializing all fields to proper empty values.

func (*NodeFeatureSpec) DeepCopy added in v0.12.0

func (in *NodeFeatureSpec) DeepCopy() *NodeFeatureSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeFeatureSpec.

func (*NodeFeatureSpec) DeepCopyInto added in v0.12.0

func (in *NodeFeatureSpec) DeepCopyInto(out *NodeFeatureSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NodeFeatureSpec) MergeInto added in v0.12.0

func (in *NodeFeatureSpec) MergeInto(out *NodeFeatureSpec)

MergeInto merges two FeatureSpecs into one. Data in the input object takes precedence (overwrite) over data of the existing object we're merging into.

type Rule

type Rule struct {
	// Name of the rule.
	Name string `json:"name"`

	// Labels to create if the rule matches.
	// +optional
	Labels map[string]string `json:"labels"`

	// 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.
	// +optional
	LabelsTemplate string `json:"labelsTemplate"`

	// Annotations to create if the rule matches.
	// +optional
	Annotations map[string]string `json:"annotations"`

	// Vars is the variables to store if the rule matches. Variables do not
	// directly inflict any changes in the node object. However, they can be
	// referenced from other rules enabling more complex rule hierarchies,
	// without exposing intermediary output values as labels.
	// +optional
	Vars map[string]string `json:"vars"`

	// VarsTemplate specifies a template to expand for dynamically generating
	// multiple variables. Data (after template expansion) must be keys with an
	// optional value (<key>[=<value>]) separated by newlines.
	// +optional
	VarsTemplate string `json:"varsTemplate"`

	// Taints to create if the rule matches.
	// +optional
	Taints []corev1.Taint `json:"taints,omitempty"`

	// ExtendedResources to create if the rule matches.
	// +optional
	ExtendedResources map[string]string `json:"extendedResources"`

	// MatchFeatures specifies a set of matcher terms all of which must match.
	// +optional
	MatchFeatures FeatureMatcher `json:"matchFeatures"`

	// MatchAny specifies a list of matchers one of which must match.
	// +optional
	MatchAny []MatchAnyElem `json:"matchAny"`
}

Rule defines a rule for node customization such as labeling.

func (*Rule) DeepCopy

func (in *Rule) DeepCopy() *Rule

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Rule.

func (*Rule) DeepCopyInto

func (in *Rule) DeepCopyInto(out *Rule)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL