From b2973e1e69f5f9a7348aeccd168d2506bebb2adc Mon Sep 17 00:00:00 2001 From: OZGCloud <ozgcloud@mgm-tp.com> Date: Wed, 18 Oct 2023 18:30:47 +0200 Subject: [PATCH] OZG-4391 OZG-4462 add helm chart support for smart documents config --- src/main/helm/templates/deployment.yaml | 9 +++++ .../helm/deployment_defaults_env_test.yaml | 39 ++++++++++++++++++- 2 files changed, 46 insertions(+), 2 deletions(-) diff --git a/src/main/helm/templates/deployment.yaml b/src/main/helm/templates/deployment.yaml index 696cc29818..a8f02ec54e 100644 --- a/src/main/helm/templates/deployment.yaml +++ b/src/main/helm/templates/deployment.yaml @@ -88,6 +88,15 @@ spec: {{- with (.Values.env).customList }} {{ toYaml . | indent 8 }} {{- end }} + {{- if ((.Values.ozgcloud).vorgang).bescheid}} + {{- range $index, $bescheid := ((.Values.ozgcloud).vorgang).bescheid }} + - name: ozgcloud_vorgang_bescheid_{{ $index }}_formId + value: {{ $bescheid.formId }} + - name: ozgcloud_vorgang_bescheid_{{ $index }}_formEngineName + value: {{ $bescheid.formEngineName }} + {{- end }} + {{- end}} + image: "{{ .Values.image.repo }}/{{ .Values.image.name }}:{{ coalesce (.Values.image).tag "latest" }}" imagePullPolicy: Always name: goofy diff --git a/src/test/helm/deployment_defaults_env_test.yaml b/src/test/helm/deployment_defaults_env_test.yaml index 6c64212eb3..473341be65 100644 --- a/src/test/helm/deployment_defaults_env_test.yaml +++ b/src/test/helm/deployment_defaults_env_test.yaml @@ -50,6 +50,7 @@ tests: content: name: spring_profiles_active value: oc, test + - it: should have service binding root set: usermanagerName: user-manager @@ -59,7 +60,8 @@ tests: content: name: SERVICE_BINDING_ROOT value: "/bindings" - - it: should have user assitance documentation url + + - it: should have user assistance documentation url templates: - templates/deployment.yaml set: @@ -69,4 +71,37 @@ tests: path: spec.template.spec.containers[0].env content: name: ozgcloud_user-assistance_documentation_url - value: http:// \ No newline at end of file + value: http:// + + - it: should have create Bescheid Konfiguration + templates: + - templates/deployment.yaml + set: + ozgcloud: + vorgang: + bescheid: + - formEngineName: AFM + formId: form_id_1 + - formEngineName: FormSolutions + formId: form_id_2 + asserts: + - contains: + path: spec.template.spec.containers[0].env + content: + name: ozgcloud_vorgang_bescheid_0_formId + value: form_id_1 + - contains: + path: spec.template.spec.containers[0].env + content: + name: ozgcloud_vorgang_bescheid_0_formEngineName + value: AFM + - contains: + path: spec.template.spec.containers[0].env + content: + name: ozgcloud_vorgang_bescheid_1_formId + value: form_id_2 + - contains: + path: spec.template.spec.containers[0].env + content: + name: ozgcloud_vorgang_bescheid_1_formEngineName + value: FormSolutions \ No newline at end of file -- GitLab