apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    io.kompose.service: monitor-webapp
  name: monitor-webapp
spec:
  replicas: 1
  selector:
    matchLabels:
      io.kompose.service: monitor-webapp
  template:
    metadata:
      labels:
        io.kompose.network/default: "true"
        io.kompose.service: monitor-webapp
    spec:
      containers:
      - image: eoscostarica506/monitor-webapp:latest
        imagePullPolicy: "Always"
        name: monitor-webapp
        envFrom:
        - configMapRef:
            name: monitor-webapp-config
        ports:
        - containerPort: 80
        - containerPort: 443
        volumeMounts:
        - mountPath: /etc/nginx/ssl-certs
          name: secret-volume
        - mountPath: /etc/nginx/conf.d
          name: configmap-volume
      restartPolicy: Always
      volumes:
        - name: secret-volume
          secret:
             secretName: monitor.io.keys
        - name: configmap-volume
          configMap:
            name:  monitor.io.conf
