apiVersion: apps/v1 kind: Deployment metadata: name: ghost-db namespace: ghost spec: selector: matchLabels: app: ghost-db template: metadata: labels: app: ghost-db spec: containers: - name: ghost-db image: mysql:8.0 envFrom: - secretRef: name: ghost-db-secret ports: - containerPort: 3306 volumeMounts: - mountPath: /var/lib/mysql name: ghost-db-pvc volumes: - name: ghost-db-pvc persistentVolumeClaim: claimName: ghost-db-pvc