kubernetes/StatefullSet&DaemonSet/nginx-rollingupdate.yml
2022-04-05 19:57:21 +02:00

35 lines
657 B
YAML

apiVersion: apps/v1
kind: Deployment
metadata:
labels:
run: nginx
name: wdrozenie-nginx
spec:
replicas: 3
selector:
matchLabels:
run: nginx
strategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 1
maxUnavailable: 1
minReadySeconds: 5
revisionHistoryLimit: 5
template:
metadata:
labels:
run: nginx
spec:
containers:
- name: nginx
image: nginx:1.18
ports:
- containerPort: 80
readinessProbe:
initialDelaySeconds: 5
periodSeconds: 5
successThreshold: 1
httpGet:
path: /
port: 80