diff --git a/prometheus-node-exporter/templates/daemonset.yaml b/prometheus-node-exporter/templates/daemonset.yaml index 0c2b2af6e..957656d9e 100644 --- a/prometheus-node-exporter/templates/daemonset.yaml +++ b/prometheus-node-exporter/templates/daemonset.yaml @@ -65,8 +65,8 @@ spec: - --collector.mountstats ports: - name: metrics - containerPort: {{ .Values.network.node_exporter.port }} - hostPort: {{ .Values.network.node_exporter.port }} + containerPort: {{ tuple "node_metrics" "internal" "metrics" . | include "helm-toolkit.endpoints.endpoint_port_lookup" }} + hostPort: {{ tuple "node_metrics" "internal" "metrics" . | include "helm-toolkit.endpoints.endpoint_port_lookup" }} {{ tuple $envAll $envAll.Values.pod.resources.node_exporter | include "helm-toolkit.snippets.kubernetes_resources" | indent 10 }} volumeMounts: - name: proc diff --git a/prometheus-node-exporter/templates/service.yaml b/prometheus-node-exporter/templates/service.yaml index 482ee48bb..5565c9984 100644 --- a/prometheus-node-exporter/templates/service.yaml +++ b/prometheus-node-exporter/templates/service.yaml @@ -33,8 +33,8 @@ spec: clusterIP: None ports: - name: metrics - port: {{ .Values.network.node_exporter.port }} - targetPort: {{ .Values.network.node_exporter.port }} + port: {{ tuple "node_metrics" "internal" "metrics" . | include "helm-toolkit.endpoints.endpoint_port_lookup" }} + targetPort: {{ tuple "node_metrics" "internal" "metrics" . | include "helm-toolkit.endpoints.endpoint_port_lookup" }} selector: {{ tuple $envAll "node_exporter" "metrics" | include "helm-toolkit.snippets.kubernetes_metadata_labels" | indent 4 }} {{- end }} diff --git a/prometheus-node-exporter/values.yaml b/prometheus-node-exporter/values.yaml index 78f0c11bf..fb33a49f9 100644 --- a/prometheus-node-exporter/values.yaml +++ b/prometheus-node-exporter/values.yaml @@ -103,10 +103,6 @@ monitoring: node_exporter: scrape: true -network: - node_exporter: - port: 9100 - endpoints: cluster_domain_suffix: cluster.local local_image_registry: @@ -134,8 +130,6 @@ endpoints: port: metrics: default: 9100 - prometheus_port: - default: 9100 manifests: configmap_bin: true