diff --git a/charts/prometheus-postgres-exporter/templates/deployment.yaml b/charts/prometheus-postgres-exporter/templates/deployment.yaml index 90ff66ec4ac5..f1cb743b0c87 100644 --- a/charts/prometheus-postgres-exporter/templates/deployment.yaml +++ b/charts/prometheus-postgres-exporter/templates/deployment.yaml @@ -150,12 +150,14 @@ spec: httpGet: path: / port: http + scheme: {{ .Values.livenessProbe.scheme }} readinessProbe: initialDelaySeconds: {{ .Values.readinessProbe.initialDelaySeconds }} timeoutSeconds: {{ .Values.readinessProbe.timeoutSeconds }} httpGet: path: / port: http + scheme: {{ .Values.readinessProbe.scheme }} resources: {{ toYaml .Values.resources | indent 12 }} {{- with .Values.securityContext }} diff --git a/charts/prometheus-postgres-exporter/templates/servicemonitor.yaml b/charts/prometheus-postgres-exporter/templates/servicemonitor.yaml index 46c680a9850b..ad6e140b4b2e 100644 --- a/charts/prometheus-postgres-exporter/templates/servicemonitor.yaml +++ b/charts/prometheus-postgres-exporter/templates/servicemonitor.yaml @@ -20,6 +20,9 @@ spec: {{- if .Values.serviceMonitor.telemetryPath }} path: {{ .Values.serviceMonitor.telemetryPath }} {{- end }} +{{- if .Values.serviceMonitor.scheme }} + scheme: {{ .Values.serviceMonitor.scheme }} +{{- end }} {{- if .Values.serviceMonitor.timeout }} scrapeTimeout: {{ .Values.serviceMonitor.timeout }} {{- end }} @@ -30,6 +33,10 @@ spec: {{- if .Values.serviceMonitor.relabelings }} relabelings: {{ toYaml .Values.serviceMonitor.relabelings | nindent 4 }} +{{- end }} +{{- with .Values.serviceMonitor.tlsConfig }} + tlsConfig: +{{- . | toYaml | nindent 6 }} {{- end }} jobLabel: {{ template "prometheus-postgres-exporter.fullname" . }} namespaceSelector: diff --git a/charts/prometheus-postgres-exporter/values.yaml b/charts/prometheus-postgres-exporter/values.yaml index 80c229dc24c7..f5193c716b2d 100644 --- a/charts/prometheus-postgres-exporter/values.yaml +++ b/charts/prometheus-postgres-exporter/values.yaml @@ -45,6 +45,10 @@ serviceMonitor: # metricRelabelings: [] # Set relabel_configs as per https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config # relabelings: [] + # HTTP scheme to use for scraping. For example `http` or `https`. Default is `http`. + # scheme: http + # TLS configuration to use when scraping the metric endpoint by Prometheus. + # tlsConfig: {} prometheusRule: enabled: false @@ -198,10 +202,12 @@ podLabels: {} # Configurable health checks livenessProbe: initialDelaySeconds: 0 + scheme: HTTP timeoutSeconds: 3 readinessProbe: initialDelaySeconds: 0 + scheme: HTTP timeoutSeconds: 1 # Labels and annotations to attach to the deployment resource