diff --git a/stable/artifactory/CHANGELOG.md b/stable/artifactory/CHANGELOG.md index e454ed0a4..1a675875b 100644 --- a/stable/artifactory/CHANGELOG.md +++ b/stable/artifactory/CHANGELOG.md @@ -1,6 +1,9 @@ # JFrog Artifactory Chart Changelog All changes to this chart will be documented in this file. +## [107.72.0] - Dec 8, 2023 +* Added the ability to provide a .Values.artifactory.structuredSystemYaml configuration which will merge with the existing .Values.artifactory.systemYaml + ## [107.71.5] - Oct 31, 2023 * Fixed - StatefulSet pod annotations changed from range to toYaml [GH-1828](https://github.com/jfrog/charts/issues/1828) * Fixed - Invalid format for awsS3V3 `multiPartLimit,multipartElementSize` in binarystore.xml. diff --git a/stable/artifactory/Chart.yaml b/stable/artifactory/Chart.yaml index bafd4c95f..911287a6d 100644 --- a/stable/artifactory/Chart.yaml +++ b/stable/artifactory/Chart.yaml @@ -21,4 +21,4 @@ name: artifactory sources: - https://github.com/jfrog/charts type: application -version: 107.71.5 +version: 107.72.0 diff --git a/stable/artifactory/templates/_helpers.tpl b/stable/artifactory/templates/_helpers.tpl index a28776f87..1c990be9d 100644 --- a/stable/artifactory/templates/_helpers.tpl +++ b/stable/artifactory/templates/_helpers.tpl @@ -487,3 +487,17 @@ Resolve fsGroup and runAsGroup on cluster based {{- printf "%s" "false" -}} {{- end -}} {{- end -}} + +{{/* +Calculate the systemYaml from structured and unstructured text input +*/}} +{{- define "artifactory.calculatedSystemYaml" -}} +{{ tpl (mergeOverwrite (include "artifactory.systemYaml" . | fromYaml) .Values.artifactory.structuredSystemYaml | toYaml) . }} +{{- end -}} + +{{/* +Calculate the systemYaml from the unstructured text input +*/}} +{{- define "artifactory.systemYaml" -}} +{{ include (print $.Template.BasePath "/_system-yaml-render.tpl") . }} +{{- end -}} diff --git a/stable/artifactory/templates/_system-yaml-render.tpl b/stable/artifactory/templates/_system-yaml-render.tpl new file mode 100644 index 000000000..369864a44 --- /dev/null +++ b/stable/artifactory/templates/_system-yaml-render.tpl @@ -0,0 +1 @@ +{{- tpl .Values.artifactory.systemYaml . -}} diff --git a/stable/artifactory/templates/artifactory-system-yaml.yaml b/stable/artifactory/templates/artifactory-system-yaml.yaml index ced943bdd..9a54f8335 100644 --- a/stable/artifactory/templates/artifactory-system-yaml.yaml +++ b/stable/artifactory/templates/artifactory-system-yaml.yaml @@ -11,5 +11,5 @@ metadata: type: Opaque stringData: system.yaml: | -{{ tpl .Values.artifactory.systemYaml . | indent 4 }} +{{ include "artifactory.calculatedSystemYaml" . | nindent 4 }} {{- end }} diff --git a/stable/artifactory/templates/artifactory-unified-secret.yaml b/stable/artifactory/templates/artifactory-unified-secret.yaml index 3306ab6f6..7da3e1b53 100644 --- a/stable/artifactory/templates/artifactory-unified-secret.yaml +++ b/stable/artifactory/templates/artifactory-unified-secret.yaml @@ -28,7 +28,7 @@ stringData: {{- if not .Values.systemYamlOverride.existingSecret }} system.yaml: | -{{ tpl .Values.artifactory.systemYaml . | indent 4 }} +{{ include "artifactory.calculatedSystemYaml" . | nindent 4 }} {{- end }} {{- if and .Values.artifactory.customSecrets }} diff --git a/stable/artifactory/values.yaml b/stable/artifactory/values.yaml index 02311d737..214c82deb 100644 --- a/stable/artifactory/values.yaml +++ b/stable/artifactory/values.yaml @@ -754,6 +754,10 @@ artifactory: event: webhooks: {{ toYaml .Values.event.webhooks | nindent 6 }} {{- end }} + + # -- Additional structured values on top of the text based 'artifactory.systemYaml'. Applied after the text based config is evaluated for templates. Enables adding and modifying YAML elements in the evaulated 'artifactory.systemYaml'. + structuredSystemYaml: {} + annotations: {} service: name: artifactory