apiVersion: apps/v1
kind: Deployment
metadata:
  name: drivercall
  labels:
    app: drivercall
spec:
  replicas: 1
  selector:
    matchLabels:
      app: drivercall
  template:
    metadata:
      labels:
        app: drivercall
    spec:
      containers:
        - name: drivercall
          image: skuser08.azurecr.io/drivercall:v11
          ports:
            - containerPort: 8080
          env:
            - name: SLEEP_ME
              valueFrom:
                configMapKeyRef:
                  name: delay-conf
                  key: sleeptime  
          readinessProbe:
            httpGet:
              path: '/actuator/health'
              port: 8080
            initialDelaySeconds: 10
            timeoutSeconds: 2
            periodSeconds: 5
            failureThreshold: 10
          livenessProbe:
            httpGet:
              path: '/actuator/health'
              port: 8080
            initialDelaySeconds: 120
            timeoutSeconds: 2
            periodSeconds: 5
            failureThreshold: 5
         