Skip to content
This repository has been archived by the owner on Oct 24, 2023. It is now read-only.

Commit

Permalink
feat: Add anti affinity to coredns deployment (#249)
Browse files Browse the repository at this point in the history
  • Loading branch information
sylr authored and jackfrancis committed Jan 9, 2019
1 parent b5dca9a commit d21ecc8
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions parts/k8s/addons/coredns.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,27 @@ spec:
annotations:
seccomp.security.alpha.kubernetes.io/pod: docker/default
spec:
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- podAffinityTerm:
labelSelector:
matchExpressions:
- key: k8s-app
operator: In
values:
- kube-dns
topologyKey: failure-domain.beta.kubernetes.io/zone
weight: 10
- podAffinityTerm:
labelSelector:
matchExpressions:
- key: k8s-app
operator: In
values:
- kube-dns
topologyKey: kubernetes.io/hostname
weight: 5
serviceAccountName: coredns
tolerations:
- key: node-role.kubernetes.io/master
Expand Down

0 comments on commit d21ecc8

Please sign in to comment.