UNCLASSIFIED

minio-vs.yaml 1.46 KB
Newer Older
still's avatar
still committed
1
{{- if and .Values.istio.enabled .Values.istio.virtualService.enabled -}}
still's avatar
still committed
2 3 4
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
still's avatar
still committed
5
  name: {{ template "minio.fullname" . }}
still's avatar
still committed
6
  namespace: {{ .Release.Namespace }}
still's avatar
still committed
7 8 9 10 11 12 13 14 15 16
  labels:
    app: {{ template "minio.fullname" . }}
    {{- include "minio.labels" . | nindent 4 }}
  {{- if .Values.istio.virtualService.labels }}
    {{ toYaml .Values.istio.virtualservice.labels | indent 4 }}
  {{- end }}
  {{- if .Values.istio.virtualService.annotations }}
  annotations:
    {{ toYaml .Values.istio.virtualService.annotations | indent 2 }}
  {{- end }}
still's avatar
still committed
17 18
spec:
  gateways:
still's avatar
still committed
19 20 21
  {{- range .Values.istio.virtualService.gateways }}
  - {{ . }}
  {{- end }}
still's avatar
still committed
22
  hosts:
still's avatar
still committed
23 24 25
  {{- range .Values.istio.virtualService.hosts }}
  - {{ tpl . $}}
  {{- end }}
still's avatar
still committed
26
  http:
Branden Cobb's avatar
Branden Cobb committed
27 28 29 30 31
    - match:
        - uri:
            prefix: /minio/v2/metrics/cluster
      route:
        - destination:
Ernest Chuang's avatar
Ernest Chuang committed
32
            host: {{ include "minio.fullname" . | trim }}-console
Branden Cobb's avatar
Branden Cobb committed
33
            port:
Ernest Chuang's avatar
Ernest Chuang committed
34
              number: {{ include "minio.servicePort" . | trim }}
Branden Cobb's avatar
Branden Cobb committed
35 36 37 38 39
      fault:
        abort:
          percentage:
            value: 100
          httpStatus: 403
Micah Nagel's avatar
Micah Nagel committed
40 41 42 43
    - match:
        - uri:
            prefix: /
      route:
still's avatar
still committed
44
        - destination:
45
            # Note: the minio operator creates the service for the tenant with a fixed name
Ernest Chuang's avatar
Ernest Chuang committed
46 47 48
            host: {{ include "minio.fullname" . | trim }}-console
            port:
              number: {{ include "minio.servicePort" . | trim }}
49
  {{ end }}