From 2bcf0fe9614bc7c538e934e76ab1ac897ac6c25b Mon Sep 17 00:00:00 2001 From: Tadas Sutkaitis Date: Wed, 27 Mar 2024 09:11:17 +0200 Subject: [PATCH] Heat: Enable custom annotations Enable custom annotations for pods [deployments, daemonsets] Change-Id: I0a2c7f1320e4f5bb28760795a83f373987f5b146 --- heat/Chart.yaml | 2 +- heat/templates/deployment-api.yaml | 1 + heat/templates/deployment-cfn.yaml | 1 + heat/templates/deployment-cloudwatch.yaml | 1 + heat/templates/deployment-engine.yaml | 1 + heat/values_overrides/annotations.yaml | 9 +++++++++ releasenotes/notes/heat.yaml | 1 + 7 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 heat/values_overrides/annotations.yaml diff --git a/heat/Chart.yaml b/heat/Chart.yaml index 8e7e67bff0..54f9823b16 100644 --- a/heat/Chart.yaml +++ b/heat/Chart.yaml @@ -14,7 +14,7 @@ apiVersion: v1 appVersion: v1.0.0 description: OpenStack-Helm Heat name: heat -version: 0.3.9 +version: 0.3.10 home: https://docs.openstack.org/heat/latest/ icon: https://www.openstack.org/themes/openstack/images/project-mascots/Heat/OpenStack_Project_Heat_vertical.png sources: diff --git a/heat/templates/deployment-api.yaml b/heat/templates/deployment-api.yaml index ca34656391..2eb72218e1 100644 --- a/heat/templates/deployment-api.yaml +++ b/heat/templates/deployment-api.yaml @@ -43,6 +43,7 @@ spec: {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }} configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} +{{ tuple "heat_api" . | include "helm-toolkit.snippets.custom_pod_annotations" | indent 8 }} {{ dict "envAll" $envAll "podName" "heat-api" "containerNames" (list "heat-api" "init" ) | include "helm-toolkit.snippets.kubernetes_mandatory_access_control_annotation" | indent 8 }} spec: serviceAccountName: {{ $serviceAccountName }} diff --git a/heat/templates/deployment-cfn.yaml b/heat/templates/deployment-cfn.yaml index 84015438d8..773972ba81 100644 --- a/heat/templates/deployment-cfn.yaml +++ b/heat/templates/deployment-cfn.yaml @@ -43,6 +43,7 @@ spec: {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }} configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} +{{ tuple "heat_cfn" . | include "helm-toolkit.snippets.custom_pod_annotations" | indent 8 }} {{ dict "envAll" $envAll "podName" "heat-cfn" "containerNames" (list "heat-cfn" "init" ) | include "helm-toolkit.snippets.kubernetes_mandatory_access_control_annotation" | indent 8 }} spec: serviceAccountName: {{ $serviceAccountName }} diff --git a/heat/templates/deployment-cloudwatch.yaml b/heat/templates/deployment-cloudwatch.yaml index f1f7353507..f9cc240737 100644 --- a/heat/templates/deployment-cloudwatch.yaml +++ b/heat/templates/deployment-cloudwatch.yaml @@ -43,6 +43,7 @@ spec: {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }} configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} +{{ tuple "heat_cloudwatch" . | include "helm-toolkit.snippets.custom_pod_annotations" | indent 8 }} spec: serviceAccountName: {{ $serviceAccountName }} {{ dict "envAll" $envAll "application" "heat" | include "helm-toolkit.snippets.kubernetes_pod_security_context" | indent 6 }} diff --git a/heat/templates/deployment-engine.yaml b/heat/templates/deployment-engine.yaml index 7b7b8adf66..fa463f023a 100644 --- a/heat/templates/deployment-engine.yaml +++ b/heat/templates/deployment-engine.yaml @@ -50,6 +50,7 @@ spec: {{ tuple $envAll | include "helm-toolkit.snippets.release_uuid" | indent 8 }} configmap-bin-hash: {{ tuple "configmap-bin.yaml" . | include "helm-toolkit.utils.hash" }} configmap-etc-hash: {{ tuple "configmap-etc.yaml" . | include "helm-toolkit.utils.hash" }} +{{ tuple "heat_engine" . | include "helm-toolkit.snippets.custom_pod_annotations" | indent 8 }} {{ dict "envAll" $envAll "podName" "heat-engine" "containerNames" (list "heat-engine" "init" ) | include "helm-toolkit.snippets.kubernetes_mandatory_access_control_annotation" | indent 8 }} {{- end }} spec: diff --git a/heat/values_overrides/annotations.yaml b/heat/values_overrides/annotations.yaml new file mode 100644 index 0000000000..17efeb1de4 --- /dev/null +++ b/heat/values_overrides/annotations.yaml @@ -0,0 +1,9 @@ +--- +annotations: + pod: + default: + custom.tld/key: "value" + custom.tld/key2: "value2" + heat_api: + another.tld/foo: "bar" +... diff --git a/releasenotes/notes/heat.yaml b/releasenotes/notes/heat.yaml index 0197786b35..d9adf39c7b 100644 --- a/releasenotes/notes/heat.yaml +++ b/releasenotes/notes/heat.yaml @@ -35,4 +35,5 @@ heat: - 0.3.7 Add 2023.2 Ubuntu Jammy overrides - 0.3.8 Fixed annotation indentation for jobs - 0.3.9 Uses uWSGI for API services + - 0.3.10 Enable custom annotations for Openstack pods ...