Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{{- define "cap-app-proxy.resources.configmap-documented-configs" }}
argoWorkflowsInsecure: {{ .Values.config.argoWorkflowsInsecure | quote }}
clusterChunkSize: {{ .Values.config.clusterChunkSize | quote }}
cors: {{ .Values.global.codefresh.url }}
cors: {{ .Values.config.cors | default .Values.global.codefresh.url }}
isConfigurationRuntime: {{ .Values.global.runtime.isConfigurationRuntime | quote }}
isExternalArgoCD: {{ .Values.global.runtime.isExternalArgoCD | quote }}
runtimeName: {{ required "global.runtime.name is required" .Values.global.runtime.name | quote}}
Expand Down
24 changes: 24 additions & 0 deletions charts/gitops-runtime/tests/app-proxy-misc_test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -295,3 +295,27 @@ tests:
- equal:
path: spec.template.spec.containers[0].name
value: cap-app-proxy

- it: app-proxy configmap should have cors from .Values.app-proxy.config.cors
template: 'app-proxy/config.yaml'
values:
- ./values/mandatory-values.yaml
set:
global.codefresh.url: "https://g.codefresh.io"
app-proxy.config.cors: "https://local.codefresh.io"
asserts:
- equal:
path: data.cors
value: "https://local.codefresh.io"

- it: app-proxy configmap should have fallback to cors from .Values.global.codefresh.url
template: 'app-proxy/config.yaml'
values:
- ./values/mandatory-values.yaml
set:
global.codefresh.url: "https://g.codefresh.io"
app-proxy.config.cors: null
asserts:
- equal:
path: data.cors
value: "https://g.codefresh.io"
2 changes: 1 addition & 1 deletion charts/gitops-runtime/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -536,7 +536,7 @@ app-proxy:
# - reduce this value if you have a lot of clusters and the cron job is failing with payload too large error
# - use 0 to sync all clusters at once
clusterChunkSize: 50
# -- Cors settings for app-proxy. This is the list of allowed domains for platform.
# -- Cors settings for app-proxy. This is the list of allowed domains for platform (comma separated).
cors: "https://g.codefresh.io"
env: {}
serviceAccount:
Expand Down