Tweak K8s deployment

This commit is contained in:
Garrett Mills 2023-01-15 19:48:22 -06:00
parent 17b51b82cc
commit 3e3ce01bc5

View File

@ -5,6 +5,7 @@ metadata:
name: garrettmills-dev name: garrettmills-dev
namespace: default namespace: default
spec: spec:
replicas: 2
selector: selector:
matchLabels: matchLabels:
app: garrettmills-dev app: garrettmills-dev
@ -15,6 +16,17 @@ spec:
labels: labels:
app: garrettmills-dev app: garrettmills-dev
spec: spec:
affinity:
podAntiAffinity:
preferredDuringSchedulingIgnoredDuringExecution:
- weight: 100
podAffinityTerm:
labelSelector:
matchExpressions:
- key: app
operator: In
values: ['garrettmills-dev']
topologyKey: 'kubernetes.io/hostname'
containers: containers:
- name: garrettmills-www - name: garrettmills-www
image: registry.millslan.net/garrettmills/www image: registry.millslan.net/garrettmills/www