diff --git a/helm/fuel-explorer/Chart.yaml b/helm/fuel-explorer/Chart.yaml index 562f4ac43..0187195f4 100644 --- a/helm/fuel-explorer/Chart.yaml +++ b/helm/fuel-explorer/Chart.yaml @@ -15,7 +15,7 @@ type: application # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: 0.1.11 +version: 0.1.12 # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to diff --git a/helm/fuel-explorer/templates/servicemonitor.yaml b/helm/fuel-explorer/templates/servicemonitor.yaml new file mode 100644 index 000000000..62f88095a --- /dev/null +++ b/helm/fuel-explorer/templates/servicemonitor.yaml @@ -0,0 +1,15 @@ +{{- if .Values.app.serviceMonitor.enabled }} +apiVersion: monitoring.coreos.com/v1 +kind: ServiceMonitor +metadata: + name: {{ include "fuel-explorer.fullname" . }} + labels: + release: {{ .Values.app.serviceMonitor.prometheusRelease }} +spec: + selector: + matchLabels: + {{- include "fuel-explorer.labels" . | nindent 4 }} + endpoints: + - path: /metrics + port: http +{{- end }} diff --git a/helm/fuel-explorer/values.yaml b/helm/fuel-explorer/values.yaml index 82263c908..783c0a3e8 100644 --- a/helm/fuel-explorer/values.yaml +++ b/helm/fuel-explorer/values.yaml @@ -83,3 +83,8 @@ nodeSelector: {} tolerations: [] affinity: {} + +app: + serviceMonitor: + enabled: true + prometheusRelease: kube-prometheus