apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: apc-load
    cluster: apc-example
  name: apc-load
spec:
  replicas: 1
  selector:
    matchLabels:
      app: apc-load
  strategy:
    rollingUpdate:
      maxSurge: 1
      maxUnavailable: 0
    type: RollingUpdate

  template:
    metadata:
      labels:
        app: apc-load
        cluster: apc-example
    spec:
      containers:
        - name: apc-load
          # remove for real clusters, useful for minikube
          imagePullPolicy: Never
          image: kubakka/endtoendexample:latest
          ports:
            - name: management
              containerPort: 8558
              protocol: TCP
            - name: http
              containerPort: 8080
              protocol: TCP
          env:
            - name: ROLE
              value: load
          readinessProbe:
            httpGet:
              path: /ready
              port: management
          livenessProbe:
            httpGet:
              path: /alive
              port: management
