diff --git a/seichi-onp-k8s/manifests/seichi-kubernetes/apps/growi-system/mongodb/statefulset.yaml b/seichi-onp-k8s/manifests/seichi-kubernetes/apps/growi-system/mongodb/statefulset.yaml index a69a779ae..0773a0dba 100644 --- a/seichi-onp-k8s/manifests/seichi-kubernetes/apps/growi-system/mongodb/statefulset.yaml +++ b/seichi-onp-k8s/manifests/seichi-kubernetes/apps/growi-system/mongodb/statefulset.yaml @@ -15,7 +15,35 @@ spec: app: mongodb spec: containers: - - name: mongodb - image: mongo:6.0 - ports: - - containerPort: 27017 + - name: mongodb + image: mongo:6.0 + ports: + - containerPort: 27017 + volumeMounts: + - name: mongo-data + mountPath: /data/db + livenessProbe: + exec: + command: + - mongo + - --eval + - "db.adminCommand('ping')" + initialDelaySeconds: 30 + periodSeconds: 10 + readinessProbe: + exec: + command: + - mongo + - --eval + - "db.adminCommand('ping')" + initialDelaySeconds: 5 + periodSeconds: 10 + volumeClaimTemplates: + - metadata: + name: mongo-data + spec: + accessModes: + - "ReadWriteOnce" + resources: + requests: + storage: 20Gi