You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
There's no provision to set custom values for Service Monitor when enabled. Looking at fluentbit-servicemonitor.yaml, the template is barebones without any placeholders to accept custom values for endpoints, selectors, labels etc.
We cannot specify namespace on resource and selectors, there's no ability to specify additional labels.
Describe the solution you'd like
This can be parameterized to accept custom values.
fluentbit-servicemonitor.yaml
{{- if .Values.Kubernetes -}}
{{- if .Values.fluentbit.enable -}}
{{- if .Values.fluentbit.serviceMonitor.enable -}}
apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
name: fluent-bit
labels:
app.kubernetes.io/name: fluent-bit
namespace: {{ template "fluent-operator.namespace" . }}
spec:
endpoints:
- port: metrics
path: {{ .Values.fluentbit.serviceMonitor.path }}
interval: {{ .Values.fluentbit.serviceMonitor.interval }}
{{- if .Values.fluentbit.serviceMonitor.secure }}
scheme: https
tlsConfig:
{{- toYaml .Values.fluentbit.serviceMonitor.tlsConfig }}
{{- end }}
scrapeTimeout: {{ .Values.fluentbit.serviceMonitor.scrapeTimeout }}
{{- with .Values.fluentbit.serviceMonitor.relabelings }}
relabelings:
{{- toYaml . | nindent 6 }}
{{- end }}
{{- with .Values.fluentbit.serviceMonitor.metricRelabelings }}
metricRelabelings:
{{- toYaml . | nindent 6 }}
{{- end }}
selector:
matchLabels:
{{- include "fluent-operator.selectorLabels" . | nindent 6 }}
{{- with .Values.fluentbit.labels }}
{{- toYaml .Values.fluentbit.labels | nindent 6}}
{{- end }}
namespaceSelector:
matchNames:
- {{ template "fluent-operator.namespace" . }}
{{- end }}
{{- end }}
{{- end }}
and modify default values.yaml -
fluentbit:
# Installs a sub chart carrying the CRDs for the fluent-bit controller. The sub chart is enabled by default.
crdsEnable: true
enable: true
serviceMonitor:
enable: false
interval: 30s
path: /api/v2/metrics/prometheus
scrapeTimeout: 10s
secure: false
tlsConfig: {}
relabelings: []
metricRelabelings: []
Additional context
No response
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
There's no provision to set custom values for Service Monitor when enabled. Looking at fluentbit-servicemonitor.yaml, the template is barebones without any placeholders to accept custom values for
endpoints
,selectors
,labels
etc.We cannot specify namespace on resource and selectors, there's no ability to specify additional labels.
Describe the solution you'd like
This can be parameterized to accept custom values.
fluentbit-servicemonitor.yaml
and modify default values.yaml -
Additional context
No response
The text was updated successfully, but these errors were encountered: