41 lines
699 B
YAML
41 lines
699 B
YAML
apiVersion: apps/v1
|
|
kind: StatefulSet
|
|
metadata:
|
|
name: valkey
|
|
spec:
|
|
selector:
|
|
matchLabels:
|
|
app: valkey
|
|
serviceName: valkey
|
|
replicas: 1
|
|
template:
|
|
metadata:
|
|
labels:
|
|
app: valkey
|
|
spec:
|
|
containers:
|
|
- name: valkey
|
|
image: docker.io/valkey/valkey:8.0.1
|
|
ports:
|
|
- containerPort: 6379
|
|
volumeMounts:
|
|
- name: data
|
|
mountPath: /data
|
|
volumeClaimTemplates:
|
|
- metadata:
|
|
name: data
|
|
spec:
|
|
accessModes: [ "ReadWriteOnce" ]
|
|
resources:
|
|
requests:
|
|
storage: 1Gi
|
|
---
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: valkey
|
|
spec:
|
|
selector:
|
|
app: valkey
|
|
ports:
|
|
- port: 6379
|