apiVersion: apps/v1
kind: Deployment
metadata:
  namespace: training
  name: backend-1.0.0
spec:
  replicas: 1
  selector:
    matchLabels:
      app: backend
      version: 1.0.0
  template:
    metadata:
      labels:
        app: backend
        version: 1.0.0
      annotations:
        sidecar.istio.io/rewriteAppHTTPProbers: "false"        
    spec:
      terminationGracePeriodSeconds: 0
      containers:
        - name: backend
          image: eu.gcr.io/loodse-training-playground/kubernetes-servicemesh/backend:1.0.0
          imagePullPolicy: Always
          ports:
            - name: http
              containerPort: 8080
          resources:
            requests:
              cpu: 500m
              memory: 512Mi
            limits:
              cpu: 500m
              memory: 512Mi
          livenessProbe:
            initialDelaySeconds: 30
            httpGet:
              path: /actuator/health/liveness
              port: 8080
          readinessProbe:
            initialDelaySeconds: 30
            httpGet:
              path: /actuator/health/readiness
              port: 8080
