From 27eb9b62ae1fb3ab48a1ec556a76c6471066da47 Mon Sep 17 00:00:00 2001 From: Dennis Bernardy Date: Thu, 22 Feb 2024 11:40:40 +0100 Subject: [PATCH] add affinity to daemonset use correct values add default values for affinity na one line --- charts/aws-fsx-csi-driver/templates/node-daemonset.yaml | 3 +++ charts/aws-fsx-csi-driver/values.yaml | 9 +++++++++ 2 files changed, 12 insertions(+) diff --git a/charts/aws-fsx-csi-driver/templates/node-daemonset.yaml b/charts/aws-fsx-csi-driver/templates/node-daemonset.yaml index 2be7c102..adac66c7 100644 --- a/charts/aws-fsx-csi-driver/templates/node-daemonset.yaml +++ b/charts/aws-fsx-csi-driver/templates/node-daemonset.yaml @@ -46,6 +46,9 @@ spec: - key: "fsx.csi.aws.com/agent-not-ready" operator: "Exists" {{- end }} + {{- with .Values.node.affinity }} + affinity: {{- toYaml . | nindent 8 }} + {{- end }} containers: - name: fsx-plugin securityContext: diff --git a/charts/aws-fsx-csi-driver/values.yaml b/charts/aws-fsx-csi-driver/values.yaml index dd098b1b..fa91d416 100644 --- a/charts/aws-fsx-csi-driver/values.yaml +++ b/charts/aws-fsx-csi-driver/values.yaml @@ -93,6 +93,15 @@ node: - operator: Exists effect: NoExecute tolerationSeconds: 300 + affinity: + nodeAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + nodeSelectorTerms: + - matchExpressions: + - key: eks.amazonaws.com/compute-type + operator: NotIn + values: + - fargate nameOverride: "" fullnameOverride: ""