DeviceTaintSelector
io.k8s.api.resource.v1alpha3.DeviceTaintSelector
source ↗
DeviceTaintSelector defines which device(s) a DeviceTaintRule applies to. The empty selector matches all devices. Without a selector, no devices are matched.
devicestringIf device is set, only devices with that name are selected. This field corresponds to slice.spec.devices[].name.Setting also driver and pool may be required to avoid ambiguity, but is not required.deviceClassNamestringIf DeviceClassName is set, the selectors defined there must be satisfied by a device to be selected. This field corresponds to class.metadata.name.driverstringIf driver is set, only devices from that driver are selected. This fields corresponds to slice.spec.driver.poolstringIf pool is set, only devices in that pool are selected.Also setting the driver name may be useful to avoid ambiguity when different drivers use the same pool name, but this is not required because selecting pools from different drivers may also be useful, for example when drivers with node-local devices use the node name as their pool name.selectors[]DeviceSelectorSelectors contains the same selection criteria as a ResourceClaim. Currently, CEL expressions are supported. All of these selectors must be satisfied.
celCELDeviceSelectorCEL contains a CEL expression for selecting a device.
expressionstring requiredExpression is a CEL expression which evaluates a single device. It must evaluate to true when the device under consideration satisfies the desired criteria, and false when it does not. Any other result is an error and causes allocation of devices to abort.The expression's input is an object named "device", which carries the following properties:- driver (string): the name of the driver which defines this device.
- attributes (map[string]object): the device's attributes, grouped by prefix
- capacity (map[string]object): the device's capacities, grouped by prefix.