diff --git a/charts/prometheus-node-exporter/templates/service.yaml b/charts/prometheus-node-exporter/templates/service.yaml index cd3ee55aa8a7..2e112f4458c7 100644 --- a/charts/prometheus-node-exporter/templates/service.yaml +++ b/charts/prometheus-node-exporter/templates/service.yaml @@ -19,6 +19,9 @@ spec: externalTrafficPolicy: {{ .Values.service.externalTrafficPolicy }} {{- end }} type: {{ .Values.service.type }} +{{- if eq .Values.service.type "ClusterIP" }} + clusterIP: "{{ .Values.service.clusterIP }}" +{{- end }} ports: - port: {{ .Values.service.port }} {{- if ( and (eq .Values.service.type "NodePort" ) (not (empty .Values.service.nodePort)) ) }} diff --git a/charts/prometheus-node-exporter/values.yaml b/charts/prometheus-node-exporter/values.yaml index 88bc435e4b2c..128c8b279a69 100644 --- a/charts/prometheus-node-exporter/values.yaml +++ b/charts/prometheus-node-exporter/values.yaml @@ -87,6 +87,7 @@ kubeRBACProxy: service: enabled: true type: ClusterIP + clusterIP: "" port: 9100 targetPort: 9100 nodePort: