diff --git a/src/digma/Chart.yaml b/src/digma/Chart.yaml index e86a5466..7176628d 100644 --- a/src/digma/Chart.yaml +++ b/src/digma/Chart.yaml @@ -1,6 +1,6 @@ apiVersion: v2 # version: this Chart version -version: 1.0.256 +version: 1.0.257 name: digma description: A Helm chart containing Digma's services and dbs home: https://github.com/digma-ai/digma diff --git a/src/digma/templates/_helpers.tpl b/src/digma/templates/_helpers.tpl index fa43ad26..b553560c 100644 --- a/src/digma/templates/_helpers.tpl +++ b/src/digma/templates/_helpers.tpl @@ -118,4 +118,9 @@ tolerations: {{- define "nodeSelector" -}} nodeSelector: {{- toYaml .Values.nodeSelector | nindent 8 }} +{{- end -}} + +{{- define "env.otlpSamplerProbability" -}} +- name: OtlpSamplerProbability + value: {{ quote .Values.digmaSelfDiagnosis.otlpSamplerProbability }} {{- end -}} \ No newline at end of file diff --git a/src/digma/templates/digma-collector-api.yaml b/src/digma/templates/digma-collector-api.yaml index 5cb35c68..bffcdc5f 100644 --- a/src/digma/templates/digma-collector-api.yaml +++ b/src/digma/templates/digma-collector-api.yaml @@ -39,6 +39,9 @@ spec: - containerPort: 5048 - containerPort: 5049 - containerPort: 5050 + {{- range .Values.digmaCollectorApi.additionalPorts | default (list) }} + - containerPort: {{ .port }} + {{- end }} env: {{- include "env.isCentralize" . | nindent 8 }} {{- include "env.licenseKey" . | nindent 8 }} @@ -60,4 +63,8 @@ spec: - name: OtlpSamplerProbability value: {{ .Values.digmaSelfDiagnosis.otlpSamplerProbability| quote}} - name: BACKEND_DEPLOYMENT_TYPE - value: {{ .Values.deploymentType | quote}} + value: {{ .Values.deploymentType | quote}} + {{- range .Values.digmaCollectorApi.envs }} + - name: {{ .name }} + value: {{ .value | quote }} + {{- end }} diff --git a/src/digma/templates/grafana.yaml b/src/digma/templates/grafana.yaml index 524d4663..3a398bf0 100644 --- a/src/digma/templates/grafana.yaml +++ b/src/digma/templates/grafana.yaml @@ -1,4 +1,4 @@ -{{- if eq .Values.digmaSelfDiagnosis.otlpExporterEndpoint "local" }} +{{- if .Values.grafana.enabled }} apiVersion: v1 kind: ConfigMap diff --git a/src/digma/templates/internal-network.yaml b/src/digma/templates/internal-network.yaml index 32d5370d..fccadba4 100644 --- a/src/digma/templates/internal-network.yaml +++ b/src/digma/templates/internal-network.yaml @@ -100,7 +100,15 @@ spec: - name: grpc protocol: TCP port: 5050 - +{{- if .Values.digmaCollectorApi.additionalPorts }} + {{- range .Values.digmaCollectorApi.additionalPorts }} + - name: {{ .name }} + port: {{ .port }} + protocol: {{ .protocol }} + {{- end }} +{{- else }} + # No additional ports specified +{{- end }} --- apiVersion: v1 diff --git a/src/digma/templates/otel-collector-df.yaml b/src/digma/templates/otel-collector-df.yaml index 1393c872..892f44f1 100644 --- a/src/digma/templates/otel-collector-df.yaml +++ b/src/digma/templates/otel-collector-df.yaml @@ -45,6 +45,8 @@ data: {{- else }} otlp: endpoint: {{.Values.digmaSelfDiagnosis.otlpExporterEndpoint}} + tls: + insecure: true {{- end }} service: diff --git a/src/digma/templates/prometheus.yaml b/src/digma/templates/prometheus.yaml index c922597d..e5ebecab 100644 --- a/src/digma/templates/prometheus.yaml +++ b/src/digma/templates/prometheus.yaml @@ -1,5 +1,4 @@ -{{- if eq .Values.digmaSelfDiagnosis.otlpExporterEndpoint "local" }} - +{{- if .Values.prometheus.enabled }} apiVersion: v1 kind: ConfigMap metadata: @@ -13,7 +12,8 @@ data: scrape_configs: - job_name: otel-collector static_configs: - - targets: [{{ printf "%s-otel-collector:7777" (.Release.Name)}}] + - targets: + - {{ tpl .Values.prometheus.target . }} --- apiVersion: apps/v1 diff --git a/src/digma/values.yaml b/src/digma/values.yaml index 089af012..61a98281 100644 --- a/src/digma/values.yaml +++ b/src/digma/values.yaml @@ -304,6 +304,7 @@ grafana: prometheus: host: "{{ .Release.Name }}-prometheus" + target: "{{ .Release.Name }}-otel-collector:7777" annotations: {} labels: {} args: [] diff --git a/src/rendered-deployment.yaml b/src/rendered-deployment.yaml index 5369eae7..7c927b3d 100644 --- a/src/rendered-deployment.yaml +++ b/src/rendered-deployment.yaml @@ -218,7 +218,7 @@ spec: - name: ApplicationVersion value: 0.3.161 - name: ChartVersion - value: 1.0.255 + value: 1.0.257 - name: OtlpSamplerProbability value: '0.3' @@ -291,7 +291,7 @@ spec: - name: ApplicationVersion value: 0.3.161 - name: ChartVersion - value: 1.0.255 + value: 1.0.257 - name: Jaeger__OtlpUrl value: http://digma-embedded-jaeger:4317 @@ -357,7 +357,7 @@ spec: - name: ApplicationVersion value: 0.3.161 - name: ChartVersion - value: 1.0.255 + value: 1.0.257 - name: Jaeger__OtlpUrl value: http://digma-embedded-jaeger:4317 - name: OtlpSamplerProbability @@ -422,7 +422,7 @@ spec: - name: ApplicationVersion value: 0.3.161 - name: ChartVersion - value: 1.0.255 + value: 1.0.257 - name: Jaeger__OtlpUrl value: http://digma-embedded-jaeger:4317 - name: OtlpSamplerProbability @@ -499,7 +499,7 @@ spec: - name: ApplicationVersion value: 0.3.161 - name: ChartVersion - value: 1.0.255 + value: 1.0.257 - name: Jaeger__OtlpUrl value: http://digma-embedded-jaeger:4317 - name: OtlpSamplerProbability @@ -566,7 +566,7 @@ spec: - name: ApplicationVersion value: 0.3.161 - name: ChartVersion - value: 1.0.255 + value: 1.0.257 - name: OtlpSamplerProbability value: '0.3'