You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+27-10Lines changed: 27 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -327,19 +327,37 @@ spec:
327
327
node-role.kubernetes.io/worker: ""
328
328
```
329
329
330
-
### Resource Injector Policy
330
+
## Feature Gates
331
331
332
-
By default, the Resource injector webhook has a failed policy of ignored, this was implemented to not block pod creation
333
-
in case the webhook is not available.
332
+
Feature gates are used to enable or disable specific features in the operator.
334
333
335
-
with a feature introduced in Kubernetes 1.28(Beta) called [MatchConditions](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#matching-requests-matchconditions)
336
-
we can move the webhook failed policy to be Fail. In this case the operator configured the Mutating webhook for the resource
337
-
injector only on pods with the secondary network annotation of `k8s.v1.cni.cncf.io/networks`.
338
-
It's possible to enable the feature with a FeatureGate via the SriovOperatorConfig object
334
+
> **NOTE**: As features mature and graduate to stable status, default settings may change, and feature gates might be removed in future releases. Keep this in mind when configuring feature gates and ensure your environment is compatible with any updates.
339
335
340
-
> **NOTE**: the feature is disabled by default
336
+
### Available Feature Gates
341
337
342
-
**Example**:
338
+
1. **Parallel NIC Configuration** (`parallelNicConfig`)
339
+
- **Description:** Allows the configuration of NICs in parallel, which can potentially reduce the time required for network setup.
340
+
- **Default:** Disabled
341
+
342
+
2. **Resource Injector Match Condition** (`resourceInjectorMatchCondition`)
343
+
- **Description:** Switches the resource injector's webhook failure policy from "Ignore" to "Fail" by utilizing the `MatchConditions` feature introduced in Kubernetes 1.28. This ensures the webhook only targets pods with the `k8s.v1.cni.cncf.io/networks` annotation, improving reliability without affecting other pods.
344
+
- **Default:** Disabled
345
+
346
+
3. **Metrics Exporter** (`metricsExporter`)
347
+
- **Description:** Enables the metrics exporter on the same node where the config-daemon is running. This helps in collecting and exporting metrics related to SR-IOV network devices.
- **Description:** Enables the firmware reset via `mstfwreset` before a system reboot. This feature is specific to Mellanox network devices and is used to ensure that the firmware is properly reset during system maintenance.
356
+
- **Default:** Disabled
357
+
358
+
### Enabling Feature Gates
359
+
360
+
To enable a feature gate, add it to your configuration file or command line with the desired state. For example, to enable the `resourceInjectorMatchCondition` feature gate, you would specify:
0 commit comments