Skip to content

Commit

Permalink
helm: add an option to set tolerations
Browse files Browse the repository at this point in the history
In some clusters, some of the Nodes might have taints which may
avoid NRI plugins DaemonSet Pods not to get scheduled on those
Nodes. Having an option to pass custom tolerations to plugins
DaemonSet object would help to ensure that Pods get scheduled
on all the desired Nodes.

Signed-off-by: Feruzjon Muyassarov <feruzjon.muyassarov@intel.com>
fmuyassarov committed Oct 16, 2023
1 parent 2a7193a commit 8ee3e70
Showing 9 changed files with 28 additions and 0 deletions.
4 changes: 4 additions & 0 deletions deployment/helm/balloons/templates/daemonset.yaml
Original file line number Diff line number Diff line change
@@ -14,6 +14,10 @@ spec:
labels:
{{- include "balloons-plugin.labels" . | nindent 8 }}
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
restartPolicy: OnFailure
serviceAccount: nri-resource-policy-balloons
nodeSelector:
2 changes: 2 additions & 0 deletions deployment/helm/balloons/values.yaml
Original file line number Diff line number Diff line change
@@ -28,3 +28,5 @@ initContainerImage:
# If not defined Chart.AppVersion will be used
#tag: unstable
pullPolicy: Always

tolerations: []
4 changes: 4 additions & 0 deletions deployment/helm/memory-qos/templates/daemonset.yaml
Original file line number Diff line number Diff line change
@@ -14,6 +14,10 @@ spec:
labels:
{{- include "memory-qos.labels" . | nindent 8 }}
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
restartPolicy: OnFailure
nodeSelector:
kubernetes.io/os: "linux"
2 changes: 2 additions & 0 deletions deployment/helm/memory-qos/values.yaml
Original file line number Diff line number Diff line change
@@ -20,3 +20,5 @@ initContainerImage:
# If not defined Chart.AppVersion will be used
#tag: unstable
pullPolicy: Always

tolerations: []
4 changes: 4 additions & 0 deletions deployment/helm/memtierd/templates/daemonset.yaml
Original file line number Diff line number Diff line change
@@ -14,6 +14,10 @@ spec:
labels:
{{- include "memtierd.labels" . | nindent 8 }}
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
restartPolicy: OnFailure
nodeSelector:
kubernetes.io/os: "linux"
2 changes: 2 additions & 0 deletions deployment/helm/memtierd/values.yaml
Original file line number Diff line number Diff line change
@@ -22,3 +22,5 @@ initContainerImage:
# If not defined Chart.AppVersion will be used
#tag: unstable
pullPolicy: Always

tolerations: []
4 changes: 4 additions & 0 deletions deployment/helm/topology-aware/templates/daemonset.yaml
Original file line number Diff line number Diff line change
@@ -14,6 +14,10 @@ spec:
labels:
{{- include "topology-aware-plugin.labels" . | nindent 8 }}
spec:
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}
restartPolicy: OnFailure
serviceAccount: nri-resource-policy-topology-aware
nodeSelector:
2 changes: 2 additions & 0 deletions deployment/helm/topology-aware/values.yaml
Original file line number Diff line number Diff line change
@@ -27,3 +27,5 @@ initContainerImage:
# If not defined Chart.AppVersion will be used
#tag: unstable
pullPolicy: Always

tolerations: []
4 changes: 4 additions & 0 deletions docs/resource-policy/installation.md
Original file line number Diff line number Diff line change
@@ -122,6 +122,7 @@ Path to the chart: `nri-resource-policy-topology-aware`
| `initImage.name` | [ghcr.io/containers/nri-plugins/config-manager](ghcr.io/containers/nri-plugins/config-manager) | init container image name |
| `initImage.tag` | unstable | init container image tag |
| `initImage.pullPolicy` | Always | init container image pull policy |
| `tolerations` | [] | specify taint toleration key, value, and effect |
#### Balloons
@@ -140,6 +141,7 @@ Path to the chart: `nri-resource-policy-balloons`
| `initImage.name` | [ghcr.io/containers/nri-plugins/config-manager](ghcr.io/containers/nri-plugins/config-manager) | init container image name |
| `initImage.tag` | unstable | init container image tag |
| `initImage.pullPolicy` | Always | init container image pull policy |
| `tolerations` | [] | specify taint toleration key, value, and effect |
#### Memtierd
@@ -157,6 +159,7 @@ Path to the chart: `nri-memtierd`
| `initImage.name` | [ghcr.io/containers/nri-plugins/config-manager](ghcr.io/containers/nri-plugins/config-manager) | init container image name |
| `initImage.tag` | unstable | init container image tag |
| `initImage.pullPolicy` | Always | init container image pull policy |
| `tolerations` | [] | specify taint toleration key, value, and effect |
#### Memory-qos
@@ -174,6 +177,7 @@ Path to the chart: `nri-memory-qos`
| `initImage.name` | [ghcr.io/containers/nri-plugins/config-manager](ghcr.io/containers/nri-plugins/config-manager) | init container image name |
| `initImage.tag` | unstable | init container image tag |
| `initImage.pullPolicy` | Always | init container image pull policy |
| `tolerations` | [] | specify taint toleration key, value, and effect |
## Manual installation

0 comments on commit 8ee3e70

Please sign in to comment.