apiVersion: apps/v1
kind: Deployment
metadata:
  name: demo-istio
spec:
  replicas: 2
  selector:
    matchLabels:
      app: demo-istio
      version: v.0.0.1
  template:
    metadata:
      labels:
        app: demo-istio
        version: v.0.0.1
    spec:
      containers:
      - name: demo-istio
        image: docker.io/jsenon/demo-istio:v.0.0.1
        env:
        - name: MY_TARGET_PING_SVC
          value: "demo-istio-pong"
        - name: MY_TARGET_PING_PORT
          value: "80"
        - name: MY_JAEGER_AGENT
          value: "jaeger-agent.istio-system:5775"
        - name: MY_SVC_SPAN_NAME
          value: "demo-istio"
        - name: "MY_ANSWER_CODE"
          value: "200"
        imagePullPolicy: Always
        ports:
        - containerPort: 9010
        volumeMounts:
        - mountPath: "/var/www/html"
          name: vol
      volumes:
        - name: vol
          persistentVolumeClaim:
            claimName: demo-vol