add nextcloud
This commit is contained in:
64
nextcloud/db/mariadb-statefulset.yaml
Normal file
64
nextcloud/db/mariadb-statefulset.yaml
Normal file
@@ -0,0 +1,64 @@
|
||||
apiVersion: apps/v1
|
||||
kind: StatefulSet
|
||||
metadata:
|
||||
name: mariadb
|
||||
spec:
|
||||
selector:
|
||||
matchLabels:
|
||||
app: mariadb
|
||||
serviceName: mariadb
|
||||
replicas: 1
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
app: mariadb
|
||||
spec:
|
||||
containers:
|
||||
- name: mariadb
|
||||
image: mariadb:10.11.11-jammy
|
||||
env:
|
||||
- name: MARIADB_ROOT_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: MYSQL_ROOT_PASSWORD
|
||||
name: nextcloud-secret
|
||||
- name: MARIADB_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: MYSQL_PASSWORD
|
||||
name: nextcloud-secret
|
||||
- name: MARIADB_USER
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: MYSQL_USER
|
||||
name: nextcloud-secret
|
||||
- name: MARIADB_DATABASE
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
key: MYSQL_DATABASE
|
||||
name: nextcloud-secret
|
||||
volumeMounts:
|
||||
- name: mariadb-data
|
||||
mountPath: /var/lib/mysql
|
||||
readinessProbe:
|
||||
exec:
|
||||
command: ["healthcheck.sh", "--connect", "--innodb_initialized"]
|
||||
initialDelaySeconds: 10
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 5
|
||||
failureThreshold: 3
|
||||
livenessProbe:
|
||||
exec:
|
||||
command: ["healthcheck.sh", "--connect", "--innodb_initialized"]
|
||||
initialDelaySeconds: 30
|
||||
periodSeconds: 10
|
||||
timeoutSeconds: 5
|
||||
failureThreshold: 5
|
||||
volumeClaimTemplates:
|
||||
- metadata:
|
||||
name: mariadb-data
|
||||
spec:
|
||||
accessModes: [ "ReadWriteOnce" ]
|
||||
resources:
|
||||
requests:
|
||||
storage: 10Gi
|
||||
Reference in New Issue
Block a user