apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    io.kompose.service: database
  name: database
  namespace: newsgac
spec:
  replicas: 1
  selector:
    matchLabels:
      name: database
  strategy:
    type: Recreate
  template:
    metadata:
      labels:
        io.kompose.service: database
        name: database
    spec:
      containers:
      - image: mongo:latest
        resources:
          limits:
            cpu: 200m
            memory: 250Mi
          requests:
            cpu: 200m
            memory: 250Mi
        name: database
        ports:
        - containerPort: 27017
        volumeMounts:
        - mountPath: /data/db
          name: database-claim0
      hostname: mongo
      restartPolicy: Always
      volumes:
      - name: database-claim0
        persistentVolumeClaim:
          claimName: database-claim0
