apiVersion: v1 kind: Pod metadata: name: client namespace: istio-vt-t27 labels: app: client annotations: sidecar.istio.io/inject: "true" spec: containers: - name: curl image: curlimages/curl:8.14.1 command: ["sleep", "infinity"] --- apiVersion: apps/v1 kind: Deployment metadata: name: drainbackend namespace: istio-vt-t27 labels: app: drainbackend spec: replicas: 1 selector: matchLabels: app: drainbackend template: metadata: labels: app: drainbackend annotations: sidecar.istio.io/inject: "true" proxy.istio.io/config: | proxyStatsMatcher: inclusionRegexps: [".*downstream_rq_active.*", ".*upstream_rq_active.*"] spec: containers: - name: httpbin image: kennethreitz/httpbin ports: - containerPort: 80 --- apiVersion: v1 kind: Service metadata: name: drainbackend namespace: istio-vt-t27 spec: selector: app: drainbackend ports: - name: http port: 80 targetPort: 80 --- apiVersion: apps/v1 kind: Deployment metadata: name: drainbackend-noskipexit namespace: istio-vt-t27 labels: app: drainbackend-noskipexit spec: replicas: 1 selector: matchLabels: app: drainbackend-noskipexit template: metadata: labels: app: drainbackend-noskipexit annotations: sidecar.istio.io/inject: "true" spec: containers: - name: httpbin image: kennethreitz/httpbin ports: - containerPort: 80 --- apiVersion: v1 kind: Service metadata: name: drainbackend-noskipexit namespace: istio-vt-t27 spec: selector: app: drainbackend-noskipexit ports: - name: http port: 80 targetPort: 80 --- apiVersion: apps/v1 kind: Deployment metadata: name: drainbackend-inboundonly namespace: istio-vt-t27 labels: app: drainbackend-inboundonly spec: replicas: 1 selector: matchLabels: app: drainbackend-inboundonly template: metadata: labels: app: drainbackend-inboundonly annotations: sidecar.istio.io/inject: "true" spec: containers: - name: httpbin image: kennethreitz/httpbin ports: - containerPort: 80 --- apiVersion: v1 kind: Service metadata: name: drainbackend-inboundonly namespace: istio-vt-t27 spec: selector: app: drainbackend-inboundonly ports: - name: http port: 80 targetPort: 80