apiVersion: v1
kind: Pod
metadata:
  name: hw-db-pod
  labels:
    app: hw-db
spec:
  containers:
  - name: hw-db-container
    image: mongo
    ports:
    - containerPort: 27017
    volumeMounts:
      - mountPath: /docker-entrypoint-initdb.d
        name: db-data
  volumes:
  - name: db-data
    hostPath:
      path: /home/docker/db
      type: Directory