diff --git a/templates/aes-internal.yaml b/templates/aes-internal.yaml index 67346889d..1b7be6338 100644 --- a/templates/aes-internal.yaml +++ b/templates/aes-internal.yaml @@ -30,6 +30,39 @@ spec: --- apiVersion: getambassador.io/v2 kind: Mapping +metadata: + name: {{ include "ambassador.fullname" . }}-devportal-assets + labels: + app.kubernetes.io/name: {{ include "ambassador.name" . }} + app.kubernetes.io/part-of: {{ .Release.Name }} + helm.sh/chart: {{ include "ambassador.chart" . }} + app.kubernetes.io/instance: {{ .Release.Name }} + {{- if .Values.deploymentTool }} + app.kubernetes.io/managed-by: {{ .Values.deploymentTool }} + {{- else }} + app.kubernetes.io/managed-by: {{ .Release.Service }} + {{- end }} + app.kubernetes.io/component: {{ include "ambassador.name" . }}-devportal-assets + product: aes +spec: + {{- if .Values.env }} + {{- if hasKey .Values.env "AMBASSADOR_ID" }} + ambassador_id: {{ .Values.env.AMBASSADOR_ID | quote }} + {{- end }} + {{- end }} + prefix: /documentation/(assets|styles)/(.*)(.css) + prefix_regex: true + regex_rewrite: + pattern: /documentation/(.*) + substitution: /docs/\1 + service: "127.0.0.1:8500" + add_response_headers: + cache-control: + value: "public, max-age=3600, immutable" + append: false +--- +apiVersion: getambassador.io/v2 +kind: Mapping metadata: # This Mapping name is what the demo uses. Sigh. name: {{ include "ambassador.fullname" . }}-devportal-demo @@ -81,4 +114,4 @@ spec: prefix: /openapi/ rewrite: "" service: "127.0.0.1:8500" -{{ end }} \ No newline at end of file +{{ end }}