diff --git a/devops/azure/chart/helm-config.yaml b/devops/azure/chart/helm-config.yaml index 89157496f323e000d9c149870ed0b7cc70c1fa05..d2c8d58c42609f7c97025822e66c6610759cbe33 100644 --- a/devops/azure/chart/helm-config.yaml +++ b/devops/azure/chart/helm-config.yaml @@ -14,3 +14,5 @@ image: repository: #{container-registry}#.azurecr.io branch: #{ENVIRONMENT_NAME}# tag: #{Build.SourceVersion}# + +istioDnsHost: #{ISTIO_DNS_HOST}# \ No newline at end of file diff --git a/devops/azure/chart/templates/virtual-service.yaml b/devops/azure/chart/templates/virtual-service.yaml new file mode 100644 index 0000000000000000000000000000000000000000..8f80398a09681913c800330a06aa837b025c212c --- /dev/null +++ b/devops/azure/chart/templates/virtual-service.yaml @@ -0,0 +1,36 @@ +--- +# Source: /devops/azure/chart/templates/virtual-service.yaml +apiVersion: networking.istio.io/v1alpha3 +kind: VirtualService +metadata: + name: {{ .Chart.Name }} + namespace: osdu +spec: + hosts: + - "{{ .Values.istioDnsHost }}" + gateways: + - istio-gateway + http: + - match: + - uri: + prefix: "/api/{{ .Chart.Name }}/v2" + route: + - destination: + host: {{ .Chart.Name }} + port: + number: 80 + corsPolicy: + maxAge: "60m" + allowCredentials: true + allowHeaders: + - Authorization + - Data-Partition-Id + - Correlation-Id + allowMethods: + - POST + - GET + - PUT + - PATCH + - DELETE + allowOrigins: + - prefix: "*" \ No newline at end of file diff --git a/devops/azure/chart/values.yaml b/devops/azure/chart/values.yaml index 7ad7ec09d9d78519cf118719ce60207873234536..dc84d481047a2dfec6747ae517b86a32c9d6534f 100644 --- a/devops/azure/chart/values.yaml +++ b/devops/azure/chart/values.yaml @@ -21,3 +21,5 @@ image: repository: community.opengroup.org:5555/osdu/platform/system/indexer-service branch: master tag: latest + +istioDnsHost: "" \ No newline at end of file