Configure AIAP pod anti-affinity
This adds an anti-affinity rule to airship-in-a-pod, so that only a single AIAP can run on a given node at a time. This is currently required because of the way AIAP configures host mounts; future work will allow multiple AIAPs to co-exist on a node, at which point this anti-affinity rule can be taken out. Change-Id: Ib8f5062a3bd2b4ea6d0a95c42cce08ac9789c362
This commit is contained in:
parent
d78f3e5c11
commit
a67286151f
|
@ -14,7 +14,17 @@ apiVersion: v1
|
||||||
kind: Pod
|
kind: Pod
|
||||||
metadata:
|
metadata:
|
||||||
name: airship-in-a-pod
|
name: airship-in-a-pod
|
||||||
|
labels:
|
||||||
|
aiap: aiap
|
||||||
spec:
|
spec:
|
||||||
|
affinity:
|
||||||
|
podAntiAffinity:
|
||||||
|
requiredDuringSchedulingIgnoredDuringExecution:
|
||||||
|
- labelSelector:
|
||||||
|
matchExpressions:
|
||||||
|
- key: aiap
|
||||||
|
operator: Exists
|
||||||
|
topologyKey: kubernetes.io/hostname
|
||||||
hostNetwork: false
|
hostNetwork: false
|
||||||
restartPolicy: Never
|
restartPolicy: Never
|
||||||
containers:
|
containers:
|
||||||
|
|
Loading…
Reference in New Issue