diff --git a/charts/sn-platform-slim/ci/disable-auth-values.yaml b/charts/sn-platform-slim/ci/disable-auth-values.yaml index c300a72d8..9c25c5149 100644 --- a/charts/sn-platform-slim/ci/disable-auth-values.yaml +++ b/charts/sn-platform-slim/ci/disable-auth-values.yaml @@ -8,3 +8,6 @@ auth: enabled: false authorization: enabled: false +proxy: + authenticateMetricsEndpoint: + enabled: false \ No newline at end of file diff --git a/charts/sn-platform-slim/templates/bookkeeper/_autorecovery.tpl b/charts/sn-platform-slim/templates/bookkeeper/_autorecovery.tpl index 5d2a11831..e59a77b7d 100644 --- a/charts/sn-platform-slim/templates/bookkeeper/_autorecovery.tpl +++ b/charts/sn-platform-slim/templates/bookkeeper/_autorecovery.tpl @@ -13,7 +13,7 @@ ${HOSTNAME}.{{ template "pulsar.autorecovery.service" . }}.{{ template "pulsar.n {{- end -}} {{/*Define broker autorecovery name*/}} -{{- define "pulsar.autorecovery.podName" -}} +{{- define "pulsar.autorecovery.containerName" -}} {{- print "autorecovery" -}} {{- end -}} @@ -21,11 +21,11 @@ ${HOSTNAME}.{{ template "pulsar.autorecovery.service" . }}.{{ template "pulsar.n {{- define "pulsar.autorecovery.datadog.annotation" -}} {{- if .Values.datadog.components.autorecovery.enabled }} {{- if eq .Values.datadog.adVersion "v1" }} -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.check_names: | +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.check_names: | ["openmetrics"] -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.init_configs: | - [{}] -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.instances: | +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.init_configs: | + {} +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.instances: | [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.autorecovery.ports.http }}/metrics", @@ -44,10 +44,10 @@ ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.instances: | ] {{- end }} {{- if eq .Values.datadog.adVersion "v2" }} -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.checks: | +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.autorecovery.ports.http }}/metrics", diff --git a/charts/sn-platform-slim/templates/bookkeeper/_bookkeeper.tpl b/charts/sn-platform-slim/templates/bookkeeper/_bookkeeper.tpl index 448b338bb..4c8af1265 100644 --- a/charts/sn-platform-slim/templates/bookkeeper/_bookkeeper.tpl +++ b/charts/sn-platform-slim/templates/bookkeeper/_bookkeeper.tpl @@ -197,7 +197,7 @@ ad.datadoghq.com/{{ template "pulsar.bookkeeper.podName" . }}.instances: | ad.datadoghq.com/{{ template "pulsar.bookkeeper.podName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.bookkeeper.ports.http }}/metrics", diff --git a/charts/sn-platform-slim/templates/broker/_broker.tpl b/charts/sn-platform-slim/templates/broker/_broker.tpl index 0702d9d5f..36a3e047d 100644 --- a/charts/sn-platform-slim/templates/broker/_broker.tpl +++ b/charts/sn-platform-slim/templates/broker/_broker.tpl @@ -199,7 +199,7 @@ ad.datadoghq.com/{{ template "pulsar.broker.podName" . }}.instances: | ad.datadoghq.com/{{ template "pulsar.broker.podName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.broker.ports.http }}/metrics", diff --git a/charts/sn-platform-slim/templates/prometheus/_prometheus.tpl b/charts/sn-platform-slim/templates/prometheus/_prometheus.tpl index 9305b8c7f..e2513d03c 100644 --- a/charts/sn-platform-slim/templates/prometheus/_prometheus.tpl +++ b/charts/sn-platform-slim/templates/prometheus/_prometheus.tpl @@ -67,7 +67,7 @@ ad.datadoghq.com/{{ template "pulsar.fullname" . }}-{{ .Values.prometheus.compon ad.datadoghq.com/{{ template "pulsar.fullname" . }}-{{ .Values.prometheus.component }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.prometheus.port }}/federate?match[]=%7B__name__%3D~%22pulsar_.%2B%7Cjvm_.%2B%7Ctopic_.%2B%22%7D", diff --git a/charts/sn-platform-slim/templates/proxy/_proxy.tpl b/charts/sn-platform-slim/templates/proxy/_proxy.tpl index 0eb638f85..934accfab 100644 --- a/charts/sn-platform-slim/templates/proxy/_proxy.tpl +++ b/charts/sn-platform-slim/templates/proxy/_proxy.tpl @@ -96,7 +96,7 @@ Define proxy log volumes {{- end }} {{/*Define proxy pod name*/}} -{{- define "pulsar.proxy.podName" -}} +{{- define "pulsar.proxy.containerName" -}} {{- print "pulsar-proxy" -}} {{- end -}} @@ -106,11 +106,11 @@ Define proxy datadog annotation {{- define "pulsar.proxy.datadog.annotation" -}} {{- if .Values.datadog.components.proxy.enabled }} {{- if eq .Values.datadog.adVersion "v1" }} -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.check_names: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.check_names: | ["openmetrics"] -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.init_configs: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.init_configs: | [{}] -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.instances: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.instances: | [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.proxy.ports.http }}/metrics/", @@ -123,7 +123,7 @@ ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.instances: | "enable_health_service_check": true, "timeout": 1000, {{- if .Values.auth.authentication.enabled }} -{{- if eq .Values.auth.authentication.provider "jwt" }} +{{- if eq .Values.auth.authentication.provider "jwt" and .Values.proxy.authenticateMetricsEndpoint.enabled }} "extra_headers": { "Authorization": "Bearer %%env_PROXY_TOKEN%%" }, @@ -136,10 +136,10 @@ ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.instances: | ] {{- end }} {{- if eq .Values.datadog.adVersion "v2" }} -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.checks: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.proxy.ports.http }}/metrics/", @@ -152,7 +152,7 @@ ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.checks: | "enable_health_service_check": true, "timeout": 1000, {{- if .Values.auth.authentication.enabled }} -{{- if eq .Values.auth.authentication.provider "jwt" }} +{{- if eq .Values.auth.authentication.provider "jwt" and .Values.proxy.authenticateMetricsEndpoint.enabled }} "extra_headers": { "Authorization": "Bearer %%env_PROXY_TOKEN%%" }, diff --git a/charts/sn-platform-slim/templates/zookeeper/_zookeeper.tpl b/charts/sn-platform-slim/templates/zookeeper/_zookeeper.tpl index 6d46d1b59..3a74407b8 100644 --- a/charts/sn-platform-slim/templates/zookeeper/_zookeeper.tpl +++ b/charts/sn-platform-slim/templates/zookeeper/_zookeeper.tpl @@ -146,7 +146,7 @@ ad.datadoghq.com/{{ template "pulsar.zookeeper.podName" . }}.instances: | ad.datadoghq.com/{{ template "pulsar.zookeeper.podName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.zookeeper.ports.metrics }}/metrics", diff --git a/charts/sn-platform/templates/bookkeeper/_autorecovery.tpl b/charts/sn-platform/templates/bookkeeper/_autorecovery.tpl index 646c71568..acd686ed1 100644 --- a/charts/sn-platform/templates/bookkeeper/_autorecovery.tpl +++ b/charts/sn-platform/templates/bookkeeper/_autorecovery.tpl @@ -13,19 +13,19 @@ ${HOSTNAME}.{{ template "pulsar.autorecovery.service" . }}.{{ template "pulsar.n {{- end -}} {{/*Define broker autorecovery name*/}} -{{- define "pulsar.autorecovery.podName" -}} -{{- print "autorecovery" -}} +{{- define "pulsar.autorecovery.containerName" -}} +{{- print "bookie-recovery" -}} {{- end -}} {{/*Define autorecovery datadog annotation*/}} {{- define "pulsar.autorecovery.datadog.annotation" -}} {{- if .Values.datadog.components.autorecovery.enabled }} {{- if eq .Values.datadog.adVersion "v1" }} -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.check_names: | +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.check_names: | ["openmetrics"] -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.init_configs: | - [{}] -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.instances: | +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.init_configs: | + {} +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.instances: | [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.autorecovery.ports.http }}/metrics", @@ -44,10 +44,10 @@ ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.instances: | ] {{- end }} {{- if eq .Values.datadog.adVersion "v2" }} -ad.datadoghq.com/{{ template "pulsar.autorecovery.podName" . }}.checks: | +ad.datadoghq.com/{{ template "pulsar.autorecovery.containerName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.autorecovery.ports.http }}/metrics", diff --git a/charts/sn-platform/templates/bookkeeper/_bookkeeper.tpl b/charts/sn-platform/templates/bookkeeper/_bookkeeper.tpl index 448b338bb..4c8af1265 100644 --- a/charts/sn-platform/templates/bookkeeper/_bookkeeper.tpl +++ b/charts/sn-platform/templates/bookkeeper/_bookkeeper.tpl @@ -197,7 +197,7 @@ ad.datadoghq.com/{{ template "pulsar.bookkeeper.podName" . }}.instances: | ad.datadoghq.com/{{ template "pulsar.bookkeeper.podName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.bookkeeper.ports.http }}/metrics", diff --git a/charts/sn-platform/templates/broker/_broker.tpl b/charts/sn-platform/templates/broker/_broker.tpl index 0702d9d5f..36a3e047d 100644 --- a/charts/sn-platform/templates/broker/_broker.tpl +++ b/charts/sn-platform/templates/broker/_broker.tpl @@ -199,7 +199,7 @@ ad.datadoghq.com/{{ template "pulsar.broker.podName" . }}.instances: | ad.datadoghq.com/{{ template "pulsar.broker.podName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.broker.ports.http }}/metrics", diff --git a/charts/sn-platform/templates/prometheus/_prometheus.tpl b/charts/sn-platform/templates/prometheus/_prometheus.tpl index 9305b8c7f..e2513d03c 100644 --- a/charts/sn-platform/templates/prometheus/_prometheus.tpl +++ b/charts/sn-platform/templates/prometheus/_prometheus.tpl @@ -67,7 +67,7 @@ ad.datadoghq.com/{{ template "pulsar.fullname" . }}-{{ .Values.prometheus.compon ad.datadoghq.com/{{ template "pulsar.fullname" . }}-{{ .Values.prometheus.component }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.prometheus.port }}/federate?match[]=%7B__name__%3D~%22pulsar_.%2B%7Cjvm_.%2B%7Ctopic_.%2B%22%7D", diff --git a/charts/sn-platform/templates/proxy/_proxy.tpl b/charts/sn-platform/templates/proxy/_proxy.tpl index 0eb638f85..934accfab 100644 --- a/charts/sn-platform/templates/proxy/_proxy.tpl +++ b/charts/sn-platform/templates/proxy/_proxy.tpl @@ -96,7 +96,7 @@ Define proxy log volumes {{- end }} {{/*Define proxy pod name*/}} -{{- define "pulsar.proxy.podName" -}} +{{- define "pulsar.proxy.containerName" -}} {{- print "pulsar-proxy" -}} {{- end -}} @@ -106,11 +106,11 @@ Define proxy datadog annotation {{- define "pulsar.proxy.datadog.annotation" -}} {{- if .Values.datadog.components.proxy.enabled }} {{- if eq .Values.datadog.adVersion "v1" }} -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.check_names: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.check_names: | ["openmetrics"] -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.init_configs: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.init_configs: | [{}] -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.instances: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.instances: | [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.proxy.ports.http }}/metrics/", @@ -123,7 +123,7 @@ ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.instances: | "enable_health_service_check": true, "timeout": 1000, {{- if .Values.auth.authentication.enabled }} -{{- if eq .Values.auth.authentication.provider "jwt" }} +{{- if eq .Values.auth.authentication.provider "jwt" and .Values.proxy.authenticateMetricsEndpoint.enabled }} "extra_headers": { "Authorization": "Bearer %%env_PROXY_TOKEN%%" }, @@ -136,10 +136,10 @@ ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.instances: | ] {{- end }} {{- if eq .Values.datadog.adVersion "v2" }} -ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.checks: | +ad.datadoghq.com/{{ template "pulsar.proxy.containerName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.proxy.ports.http }}/metrics/", @@ -152,7 +152,7 @@ ad.datadoghq.com/{{ template "pulsar.proxy.podName" . }}.checks: | "enable_health_service_check": true, "timeout": 1000, {{- if .Values.auth.authentication.enabled }} -{{- if eq .Values.auth.authentication.provider "jwt" }} +{{- if eq .Values.auth.authentication.provider "jwt" and .Values.proxy.authenticateMetricsEndpoint.enabled }} "extra_headers": { "Authorization": "Bearer %%env_PROXY_TOKEN%%" }, diff --git a/charts/sn-platform/templates/vault/_vault.tpl b/charts/sn-platform/templates/vault/_vault.tpl index 47e250b72..134bb9443 100644 --- a/charts/sn-platform/templates/vault/_vault.tpl +++ b/charts/sn-platform/templates/vault/_vault.tpl @@ -50,8 +50,8 @@ ad.datadoghq.com/vault.instances: | {{- if eq .Values.datadog.adVersion "v2" }} ad.datadoghq.com/vault.checks: | { - "openmetrics": { - "init_config": [{}], + "vault": { + "init_config": {}, "instances": [ { "api_url": "http://%%host%%:8200/v1", diff --git a/charts/sn-platform/templates/zookeeper/_zookeeper.tpl b/charts/sn-platform/templates/zookeeper/_zookeeper.tpl index 6d46d1b59..3a74407b8 100644 --- a/charts/sn-platform/templates/zookeeper/_zookeeper.tpl +++ b/charts/sn-platform/templates/zookeeper/_zookeeper.tpl @@ -146,7 +146,7 @@ ad.datadoghq.com/{{ template "pulsar.zookeeper.podName" . }}.instances: | ad.datadoghq.com/{{ template "pulsar.zookeeper.podName" . }}.checks: | { "openmetrics": { - "init_config": [{}], + "init_config": {}, "instances": [ { "openmetrics_endpoint": "http://%%host%%:{{ .Values.zookeeper.ports.metrics }}/metrics",