Add API VirtualService back
Summary
The VS for the Anchore API was removed in the latest tag (2.0.2-bb.1).
What is the current behavior?
Pipelines that depend on that endpoint are failing to reach it as it was deleted.
Possible fixes
Add this template back to this file
{{- if and .Values.istio.enabled .Values.istio.api.enabled }}
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: anchore-engine-api-service
namespace: {{ .Release.Namespace }}
{{- if .Values.istio.api.labels }}
labels:
{{ toYaml .Values.istio.api.labels | indent 4 }}
{{- end }}
{{- if .Values.istio.api.annotations }}
annotations:
{{ toYaml .Values.istio.api.annotations | indent 4 }}
{{- end }}
spec:
gateways:
{{- range .Values.istio.api.gateways }}
- {{ . }}
{{- end }}
hosts:
{{- range .Values.istio.api.hosts }}
- {{ tpl . $ }}
{{- end }}
http:
- match:
- uri:
prefix: /metrics
route:
- destination:
port:
number: {{ .Values.anchoreApi.service.port }}
host: {{ .Release.Name }}-anchore-engine-api
fault:
abort:
percentage:
value: 100
httpStatus: 403
- match:
- uri:
prefix: /
route:
- destination:
port:
number: {{ .Values.anchoreApi.service.port }}
host: {{ .Release.Name }}-anchore-engine-api
{{- end }}
/cc {put CODEOWNERs @githandles here}