diff --git a/helm/api7ee-demo-k8s/templates/configmap-adc.yaml b/helm/api7ee-demo-k8s/templates/configmap-adc.yaml index c7588ef..29ec7ba 100644 --- a/helm/api7ee-demo-k8s/templates/configmap-adc.yaml +++ b/helm/api7ee-demo-k8s/templates/configmap-adc.yaml @@ -38,10 +38,10 @@ data: {{- end }} {{- if .Values.api7.plugins.cors.enabled }} cors: - allow_origins: {{ .Values.api7.plugins.cors.allowOrigins | toJson }} - allow_methods: {{ .Values.api7.plugins.cors.allowMethods | toJson }} - allow_headers: {{ .Values.api7.plugins.cors.allowHeaders | toJson }} - expose_headers: {{ .Values.api7.plugins.cors.exposeHeaders | toJson }} + allow_origins: {{ .Values.api7.plugins.cors.allowOrigins | join "," | quote }} + allow_methods: {{ .Values.api7.plugins.cors.allowMethods | join "," | quote }} + allow_headers: {{ .Values.api7.plugins.cors.allowHeaders | join "," | quote }} + expose_headers: {{ .Values.api7.plugins.cors.exposeHeaders | join "," | quote }} max_age: {{ .Values.api7.plugins.cors.maxAge }} allow_credential: {{ .Values.api7.plugins.cors.allowCredentials }} {{- end }} @@ -72,10 +72,10 @@ data: {{- end }} {{- if .Values.api7.plugins.cors.enabled }} cors: - allow_origins: {{ .Values.api7.plugins.cors.allowOrigins | toJson }} - allow_methods: {{ .Values.api7.plugins.cors.allowMethods | toJson }} - allow_headers: {{ .Values.api7.plugins.cors.allowHeaders | toJson }} - expose_headers: {{ .Values.api7.plugins.cors.exposeHeaders | toJson }} + allow_origins: {{ .Values.api7.plugins.cors.allowOrigins | join "," | quote }} + allow_methods: {{ .Values.api7.plugins.cors.allowMethods | join "," | quote }} + allow_headers: {{ .Values.api7.plugins.cors.allowHeaders | join "," | quote }} + expose_headers: {{ .Values.api7.plugins.cors.exposeHeaders | join "," | quote }} max_age: {{ .Values.api7.plugins.cors.maxAge }} allow_credential: {{ .Values.api7.plugins.cors.allowCredentials }} {{- end }} @@ -100,10 +100,10 @@ data: {{- end }} {{- if .Values.api7.plugins.cors.enabled }} cors: - allow_origins: {{ .Values.api7.plugins.cors.allowOrigins | toJson }} - allow_methods: {{ .Values.api7.plugins.cors.allowMethods | toJson }} - allow_headers: {{ .Values.api7.plugins.cors.allowHeaders | toJson }} - expose_headers: {{ .Values.api7.plugins.cors.exposeHeaders | toJson }} + allow_origins: {{ .Values.api7.plugins.cors.allowOrigins | join "," | quote }} + allow_methods: {{ .Values.api7.plugins.cors.allowMethods | join "," | quote }} + allow_headers: {{ .Values.api7.plugins.cors.allowHeaders | join "," | quote }} + expose_headers: {{ .Values.api7.plugins.cors.exposeHeaders | join "," | quote }} max_age: {{ .Values.api7.plugins.cors.maxAge }} allow_credential: {{ .Values.api7.plugins.cors.allowCredentials }} {{- end }}