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/service.yaml b/devops/azure/chart/templates/service.yaml index eb5d124b64e3fdc13f20c0c0480aa1fd13a7a173..a1587090bdf893b2b9ce504bc027bd162f6249f3 100644 --- a/devops/azure/chart/templates/service.yaml +++ b/devops/azure/chart/templates/service.yaml @@ -23,5 +23,6 @@ spec: - protocol: TCP port: 80 targetPort: 80 + name: http selector: app: {{ .Chart.Name }} diff --git a/devops/azure/chart/templates/virtual-service.yaml b/devops/azure/chart/templates/virtual-service.yaml new file mode 100644 index 0000000000000000000000000000000000000000..bdde0f07dafff4c5029d311a62db1fe87c10de34 --- /dev/null +++ b/devops/azure/chart/templates/virtual-service.yaml @@ -0,0 +1,35 @@ +--- +# 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 }}/v1" + route: + - destination: + host: {{ .Chart.Name }} + port: + number: 80 + corsPolicy: + maxAge: "60m" + allowCredentials: true + allowHeaders: + - Authorization + - Data-Partition-Id + - Correlation-Id + allowMethods: + - POST + - GET + - 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 90c2c83ff2333108dc351f642fce4bcba46fc3fb..05e5ffd27a959524f9607f8fc11a653466fbcc03 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/partition branch: master tag: latest + +istioDnsHost: "" \ No newline at end of file