apiVersion: v1
kind: ReplicationController
metadata:
  annotations:
    operator.synopsys.com/group-dependencies: "ConfigMap,AlertSecret"
  labels:
    operator.synopsys.com/group-id: "Alert"
    name: $(ALERT_CR_NAME)-alert
  name: $(ALERT_CR_NAME)-alert
spec:
  replicas: 1
  selector:
    name: $(ALERT_CR_NAME)-alert
  template:
    metadata:
      labels:
        name: $(ALERT_CR_NAME)-alert
      name: $(ALERT_CR_NAME)-alert
    spec:
      containers:
        - envFrom:
            - configMapRef:
                name: $(ALERT_CR_NAME)-blackduck-alert-config
            - secretRef:
                name: $(ALERT_CR_NAME)-alert-secret
          image: docker.io/blackducksoftware/blackduck-alert:4.0.0
          imagePullPolicy: Always
          livenessProbe:
            exec:
              command:
                - /usr/local/bin/docker-healthcheck.sh
                - https://localhost:8443/alert/api/about
            failureThreshold: 5
            initialDelaySeconds: 240
            periodSeconds: 30
            timeoutSeconds: 10
          name: alert
          ports:
            - containerPort: 8443
              protocol: TCP
          resources:
            limits:
              memory: 2560M
            requests:
              memory: 2560M
          volumeMounts:
            - mountPath: /opt/blackduck/alert/alert-config
              name: dir-alert
      dnsPolicy: ClusterFirst
      volumes:
        - emptyDir: {}
          name: dir-alert
