apiVersion: v1
kind: Pod
metadata:
  name: mysql
  labels:
    app: mysql
spec:
  containers:
    - name: mysql
      image: mariadb
      env:
        - name: MYSQL_DB_POSTGRES
          value: mariadb
        - name: MYSQL_DB_USER
          value: nextcloud
        - name: MYSQL_DB_PASSWORD
          value: secret
        - name: MYSQL_DB_HOST
          value: admin
      volumeMounts:
        - mountPath: /var/lib/mysql
          name: mysql
  volumes:
    - name: mysql
      persistentVolumeClaim:
        claimName: mysql-pv-claim
