Move Guide topic: Assigning Pods to Nodes. (#3071)

This commit is contained in:
Steve Perry
2017-03-28 20:59:32 -07:00
committed by GitHub
parent b60e2fe334
commit b974f72bd3
6 changed files with 484 additions and 406 deletions
@@ -0,0 +1,27 @@
apiVersion: v1
kind: Pod
metadata:
name: with-pod-affinity
spec:
affinity:
podAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- labelSelector:
matchExpressions:
- key: security
operator: In
values:
- S1
topologyKey: failure-domain.beta.kubernetes.io/zone
podAntiAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
- labelSelector:
matchExpressions:
- key: security
operator: In
values:
- S2
topologyKey: kubernetes.io/hostname
containers:
- name: with-pod-affinity
image: gcr.io/google_containers/pause:2.0