bugfix:修复当proxy.enable=no时traffic-engine exporter采集不到数据的错误

This commit is contained in:
fumingwei
2022-11-18 14:29:06 +08:00
parent d46bce0bf0
commit 56ac368555
3 changed files with 10 additions and 2 deletions

View File

@@ -92,3 +92,11 @@ enable_breakpad_upload=0
{{- end }}
{{- $proto_name }}
{{- end -}}
{{- define "traffic-engine.merge-exporter.merge-urls" -}}
{{- if and (eq .Values.proxy.enable .Values.define_enable_val_yes) (ge (len .Values.tfe_affinity) 1) }}
{{- print "value: http://localhost:9273/metrics http://localhost:9001/metrics http://localhost:9002/metrics" }}
{{- else }}
{{- print "value: http://localhost:9273/metrics http://localhost:9002/metrics" }}
{{- end }}
{{- end -}}

View File

@@ -243,7 +243,7 @@ spec:
env:
# space-separated list of URLs
- name: MERGER_URLS
value: {{ .Values.mergeExporter.mergeUrls }}
{{- include "traffic-engine.merge-exporter.merge-urls" . | nindent 10 }}
- name: MERGER_PORT
value: "{{ .Values.mergeExporter.mergePort }}"

View File

@@ -194,7 +194,7 @@ mergeExporter:
pullPolicy: Never
tag: "v0.2.0"
port: "9004"
mergeUrls: "http://localhost:9273/metrics http://localhost:9001/metrics http://localhost:9002/metrics"
# mergeUrls: "http://localhost:9273/metrics http://localhost:9001/metrics http://localhost:9002/metrics"
mergePort: "9004"
deployment: