Skip to content

Commit

Permalink
Merge pull request #91 from jcaamano/fix-affinity
Browse files Browse the repository at this point in the history
Replace nodeSelector with nodeAffinity master role
  • Loading branch information
pliurh authored Jun 15, 2021
2 parents bb85ac9 + de0891b commit fc360d9
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
8 changes: 7 additions & 1 deletion bindata/manifests/operator-webhook/server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,13 @@ spec:
serviceAccountName: operator-webhook-sa
nodeSelector:
beta.kubernetes.io/os: linux
node-role.kubernetes.io/master:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/master
operator: Exists
tolerations:
- key: "node-role.kubernetes.io/master"
operator: Exists
Expand Down
8 changes: 7 additions & 1 deletion bindata/manifests/webhook/server.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,13 @@ spec:
serviceAccountName: network-resources-injector-sa
nodeSelector:
beta.kubernetes.io/os: linux
node-role.kubernetes.io/master:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/master
operator: Exists
tolerations:
- key: "node-role.kubernetes.io/master"
operator: Exists
Expand Down
9 changes: 7 additions & 2 deletions deploy/operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,13 @@ spec:
labels:
name: sriov-network-operator
spec:
nodeSelector:
node-role.kubernetes.io/master: ""
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: node-role.kubernetes.io/master
operator: Exists
tolerations:
- effect: NoSchedule
key: node-role.kubernetes.io/master
Expand Down

0 comments on commit fc360d9

Please sign in to comment.