k8s_website/website_deployment.yml

42 lines
877 B
YAML

---
apiVersion: apps/v1
kind: Deployment
metadata:
name: website
spec:
selector:
matchLabels:
app: website
replicas: 1
strategy:
type: RollingUpdate
template:
metadata:
labels:
app: website
spec:
affinity:
nodeAffinity:
requiredDuringSchedulingIgnoredDuringExecution:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/arch
operator: In
values:
- arm64
containers:
- name: website
image: nginx
ports:
- containerPort: 80
name: "website"
volumeMounts:
- name: website
mountPath: "/usr/share/nginx/html"
volumes:
- name: website
persistentVolumeClaim:
claimName: website-pvc
# EOF