29 lines
526 B
YAML
29 lines
526 B
YAML
|
apiVersion: apps/v1
|
||
|
kind: StatefulSet
|
||
|
metadata:
|
||
|
name: mariadb
|
||
|
labels:
|
||
|
app: mariadb
|
||
|
spec:
|
||
|
replicas: 1
|
||
|
serviceName: mariadb
|
||
|
selector:
|
||
|
matchLabels:
|
||
|
app: mariadb
|
||
|
template:
|
||
|
metadata:
|
||
|
labels:
|
||
|
app: mariadb
|
||
|
spec:
|
||
|
containers:
|
||
|
- name: mariadb
|
||
|
image: mariadb
|
||
|
imagePullPolicy: Never
|
||
|
volumeMounts:
|
||
|
- name: mariadb
|
||
|
mountPath: /var/lib/mysql
|
||
|
volumes:
|
||
|
- name: mariadb
|
||
|
persistentVolumeClaim:
|
||
|
claimName: mariadb
|