diff --git a/Chart.yaml b/Chart.yaml index b1e5b5a..b05c3c1 100644 --- a/Chart.yaml +++ b/Chart.yaml @@ -6,5 +6,5 @@ description: |- and maintained by your friends at Equinix Metal type: application -version: 0.1.11 +version: 0.1.12 appVersion: "0.1.0" diff --git a/README.md b/README.md index 99c81d2..922fcd6 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Krakend -![Version: 0.1.11](https://img.shields.io/badge/Version-0.1.11-informational?style=for-the-badge) +![Version: 0.1.12](https://img.shields.io/badge/Version-0.1.12-informational?style=for-the-badge) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=for-the-badge) ![AppVersion: 0.1.0](https://img.shields.io/badge/AppVersion-0.1.0-informational?style=for-the-badge) @@ -74,11 +74,10 @@ please refer to [the official krakend documentation](https://www.krakend.io/docs | serviceAccount.annotations | object | `{}` | The annotations to use for the service account | | serviceAccount.create | bool | `true` | Specifies whether a service account should be created | | serviceAccount.name | string | `""` | The name of the service account to use. If not set and create is true, a name is generated using the fullname template | -| serviceMonitor | object | `{"annotations":{},"enabled":false,"interval":"10s","labels":{},"scrapeTimeout":"10s","targetPort":9091}` | The serviceMonitor configures a ServiceMonitor for your application | +| serviceMonitor | object | `{"annotations":{},"enabled":false,"interval":"10s","scrapeTimeout":"10s","targetPort":9091}` | The serviceMonitor configures a ServiceMonitor for your application | | serviceMonitor.annotations | object | `{}` | Annotations to add to ServiceMonitor | | serviceMonitor.enabled | bool | `false` | Set to true to create a default ServiceMonitor for your application | | serviceMonitor.interval | string | `"10s"` | Interval for scrape metrics. | -| serviceMonitor.labels | object | `{}` | Labels to add to ServiceMonitor | | serviceMonitor.scrapeTimeout | string | `"10s"` | time out interval when scraping metrics | | serviceMonitor.targetPort | int | `9091` | prometheus metrics port exposed by krakend | | strategy | object | `{}` | The strategy for the krakend deployment. This can either be a `deployment` or a `rollout` strategy. For more information on the Argo Rollout strategy, see https://argo-rollouts.readthedocs.io/en/stable/features/specification/ | diff --git a/templates/service-monitor.yaml b/templates/service-monitor.yaml index f4db4f7..d1b751b 100644 --- a/templates/service-monitor.yaml +++ b/templates/service-monitor.yaml @@ -12,8 +12,14 @@ metadata: {{- end }} {{- end }} spec: + namespaceSelector: + matchNames: + - {{ .Release.Namespace }} selector: matchLabels: {{- include "krakend.selectorLabels" . | nindent 6 }} endpoints: - - port: metrics + - interval: {{ .Values.serviceMonitor.interval }} + scrapeTimeout: {{ .Values.serviceMonitor.scrapeTimeout }} + path: /metrics + targetPort: {{ .Values.serviceMonitor.targetPort }} {{- end }} diff --git a/values.yaml b/values.yaml index 79ee84c..c5d982e 100644 --- a/values.yaml +++ b/values.yaml @@ -210,8 +210,6 @@ readinessProbe: serviceMonitor: # -- (bool) Set to true to create a default ServiceMonitor for your application enabled: false - # -- Labels to add to ServiceMonitor - labels: {} # -- Annotations to add to ServiceMonitor annotations: {} # -- Interval for scrape metrics.