apiVersion: apps/v1
kind: Deployment
metadata:
  name: configurator-api
  labels:
    app: configurator-api
spec:
  replicas: 1
  selector:
    matchLabels:
      app: configurator-api
  template:
    metadata:
      labels:
        app: configurator-api
    spec:
      containers:
        - image: 279559645400.dkr.ecr.us-west-1.amazonaws.com/solui/configurator-api-server:G8R2i020
          name: configurator-api
          imagePullPolicy: Always
          ports:
            - containerPort: 8050
          livenessProbe:
            httpGet:
              path: /ui-schema/health
              port: 8050
            initialDelaySeconds: 35
            periodSeconds: 10
            timeoutSeconds: 5
            failureThreshold: 3
            successThreshold: 1
          readinessProbe:
            httpGet:
              path: /ui-schema/health
              port: 8050
            initialDelaySeconds: 30
            failureThreshold: 5
            periodSeconds: 10
          resources:
            requests:
              cpu: 100m
              memory: 200Mi
            limits:
              cpu: 200m
              memory: 400Mi
          volumeMounts:
            - mountPath: /opt/configurator_api/.env
              subPath: .env
              name: configurator-api-mount
      volumes:
        - name: configurator-api-mount
          configMap:
            name: configurator-api-cm
      restartPolicy: Always
