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

fix: Add field in the nicclusterpolicy helm template for nodeAffinity #349

Merged
merged 1 commit into from
Jul 14, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion deployment/network-operator/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,7 @@ We have introduced the following Chart parameters.
| `operator.tag` | string | `None` | Network Operator image tag, if `None`, then the Chart's `appVersion` will be used |
| `operator.imagePullSecrets` | list | `[]` | An optional list of references to secrets to use for pulling Network Operator image |
| `deployCR` | bool | `false` | Deploy `NicClusterPolicy` custom resource according to provided parameters |
| `nodeAffinity` | yaml | `` | Override the node affinity for various Daemonsets deployed by network operator, e.g. whereabouts, multus, cni-plugins. |

#### imagePullSecrets customization
To provide imagePullSecrets object references, you need to specify them using a following structure:
Expand All @@ -326,7 +327,6 @@ imagePullSecrets:
- image-pull-secret2
```


### NicClusterPolicy Custom resource parameters

#### Mellanox OFED driver
Expand Down Expand Up @@ -460,6 +460,7 @@ Specifies components to deploy in order to facilitate a secondary network in Kub
| `ipamPlugin.repository` | string | `ghcr.io/k8snetworkplumbingwg` | IPAM CNI Plugin image repository |
| `ipamPlugin.version` | string | `v0.5.1-amd64` | IPAM CNI Plugin image version |
| `ipamPlugin.imagePullSecrets` | list | `[]` | An optional list of references to secrets to use for pulling any of the IPAM CNI Plugin image |

## Deployment Examples

As there are several parameters that are required to be provided to create the custom resource during
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ kind: NicClusterPolicy
metadata:
name: nic-cluster-policy
spec:
{{- if .Values.nodeAffinity }}
nodeAffinity:
{{ toYaml .Values.nodeAffinity | indent 4 }}
{{- end }}
{{- if .Values.ofedDriver.deploy }}
ofedDriver:
image: {{ .Values.ofedDriver.image }}
Expand Down
4 changes: 4 additions & 0 deletions deployment/network-operator/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -242,5 +242,9 @@ secondaryNetwork:
version: v0.5.2-amd64
# imagePullSecrets: []

# Can be set to nicclusterpolicy and override other ds node affinity,
# e.g. https://github.com/Mellanox/network-operator/blob/master/manifests/stage-multus-cni/0050-multus-ds.yml#L26-L36
#nodeAffinity:

test:
pf: ens2f0