diff --git a/charts/redis-ha/Chart.yaml b/charts/redis-ha/Chart.yaml index 029613b..0f5b134 100644 --- a/charts/redis-ha/Chart.yaml +++ b/charts/redis-ha/Chart.yaml @@ -6,7 +6,7 @@ keywords: - redis - keyvalue - database -version: 4.16.0 +version: 4.17.4 appVersion: 6.2.5 description: This Helm chart provides a highly available Redis implementation with a master/slave configuration and uses Sentinel sidecars for failover management icon: https://upload.wikimedia.org/wikipedia/en/thumb/6/6b/Redis_Logo.svg/1200px-Redis_Logo.svg.png diff --git a/charts/redis-ha/README.md b/charts/redis-ha/README.md index 8c0f0b2..c65b60f 100644 --- a/charts/redis-ha/README.md +++ b/charts/redis-ha/README.md @@ -151,18 +151,20 @@ The following table lists the configurable parameters of the Redis chart and the | `exporter.serviceMonitor.telemetryPath` | Path to redis-exporter telemetry-path | `/metrics` | | `exporter.serviceMonitor.labels` | Labels for the servicemonitor passed to Prometheus Operator | `{}` | | `exporter.serviceMonitor.timeout` | How long until a scrape request times out. If not set, the Prometheus default scape timeout is used | `nil` | +| `exporter.serviceMonitor.relabelings` | RelabelConfigs to apply to samples before scraping. +| `exporter.serviceMonitor.metricRelabelings` | MetricRelabelConfigs to apply to samples after scraping, but before ingestion. | `haproxy.enabled` | Enabled HAProxy LoadBalancing/Proxy | `false` | | `haproxy.replicas` | Number of HAProxy instances | `3` | | `haproxy.servicePort` | Modify HAProxy service port | `6379` | -| `haproxy.containerPort` | Modify HAProxy deployment container port | `6379` +| `haproxy.containerPort` | Modify HAProxy deployment container port | `6379` | `haproxy.image.repository`| HAProxy Image Repository | `haproxy` | | `haproxy.image.tag` | HAProxy Image Tag | `2.4.2` | | `haproxy.image.pullPolicy`| HAProxy Image PullPolicy | `IfNotPresent` | | `haproxy.imagePullSecrets`| Reference to one or more secrets to be used when pulling haproxy images | [] | | `haproxy.tls.enabled` | If "true" this will enable TLS termination on haproxy | `false` -| `haproxy.tls.secretName` | Secret containing the .pem file | `""` +| `haproxy.tls.secretName` | Secret containing the .pem file | `""` | `haproxy.tls.certMountPath` | Path to mount the secret that contains the certificates. haproxy | `false` -| `haproxy.tls.secretName` | Secret containing the .pem file | `""` +| `haproxy.tls.secretName` | Secret containing the .pem file | `""` | `haproxy.annotations` | HAProxy template annotations | `{}` | | `haproxy.customConfig` | Allows for custom config-haproxy.cfg file to be applied. If this is used then default config will be overwriten |``| | `haproxy.extraConfig` | Allows to place any additional configuration section to add to the default config-haproxy.cfg |``| @@ -172,7 +174,7 @@ The following table lists the configurable parameters of the Redis chart and the | `haproxy.podSecurityPolicy.create` | Specifies whether a PodSecurityPolicy should be created | `false` | | `haproxy.service.type` | HAProxy service type "ClusterIP", "LoadBalancer" or "NodePort" | `ClusterIP` | | `haproxy.service.nodePort` | HAProxy service nodePort value (haproxy.service.type must be NodePort) | not set | -| `haproxy.image.serviceAccountName`| HAProxy serviceAccountName | `default` +| `haproxy.image.serviceAccountName`| HAProxy serviceAccountName | `default` | `haproxy.service.externalTrafficPolicy`| HAProxy service externalTrafficPolicy value (haproxy.service.type must be LoadBalancer) | not set | | `haproxy.service.annotations` | HAProxy service annotations | `{}` | | `haproxy.stickyBalancing` | HAProxy sticky load balancing to Redis nodes. Helps with connections shutdown. | `false` | @@ -188,6 +190,8 @@ The following table lists the configurable parameters of the Redis chart and the | `haproxy.metrics.serviceMonitor.telemetryPath` | Path to HAProxy metrics telemetry-path | `/metrics` | | `haproxy.metrics.serviceMonitor.labels` | Labels for the HAProxy metrics servicemonitor passed to Prometheus Operator | `{}` | | `haproxy.metrics.serviceMonitor.timeout` | How long until a scrape request times out. If not set, the Prometheus default scape timeout is used | `nil` | +| `haproxy.metrics.serviceMonitor.relabelings` | RelabelConfigs to apply to samples before scraping. +| `haproxy.metrics.serviceMonitor.metricRelabelings` | MetricRelabelConfigs to apply to samples after scraping, but before ingestion. | `haproxy.init.resources` | Extra init resources | `{}` | | `haproxy.timeout.connect` | haproxy.cfg `timeout connect` setting | `4s` | | `haproxy.timeout.server` | haproxy.cfg `timeout server` setting | `30s` | @@ -374,6 +378,6 @@ If any of the checks above fails - the redis server reinitialisation happens (it # Change Log ## 4.14.9 - ** POTENTIAL BREAKING CHANGE. ** -Introduced the ability to change the Haproxy Deployment container pod +Introduced the ability to change the Haproxy Deployment container pod - Container port in redis-haproxy-deployment.yam has been changed. Was **redis.port** To **haproxy.containerPort**. Default value is 6379. -- Port in redis-haproxy-service.yaml has been changed. Was **redis.port** To **haproxy.servicePort**. Default value is 6379. +- Port in redis-haproxy-service.yaml has been changed. Was **redis.port** To **haproxy.servicePort**. Default value is 6379. diff --git a/charts/redis-ha/templates/redis-ha-servicemonitor.yaml b/charts/redis-ha/templates/redis-ha-servicemonitor.yaml index 4cf96f4..608bfc4 100644 --- a/charts/redis-ha/templates/redis-ha-servicemonitor.yaml +++ b/charts/redis-ha/templates/redis-ha-servicemonitor.yaml @@ -23,6 +23,14 @@ spec: {{- end }} {{- if .Values.exporter.serviceMonitor.timeout }} scrapeTimeout: {{ .Values.exporter.serviceMonitor.timeout }} +{{- end }} +{{- if .Values.exporter.serviceMonitor.metricRelabelings }} + metricRelabelings: + {{- toYaml .Values.exporter.serviceMonitor.metricRelabelings | nindent 6 }} +{{- end }} +{{- if .Values.exporter.serviceMonitor.relabelings }} + relabelings: + {{- toYaml .Values.exporter.serviceMonitor.relabelings | nindent 6 }} {{- end }} jobLabel: {{ template "redis-ha.fullname" . }} namespaceSelector: diff --git a/charts/redis-ha/templates/redis-haproxy-servicemonitor.yaml b/charts/redis-ha/templates/redis-haproxy-servicemonitor.yaml index 056ce4b..5038a01 100644 --- a/charts/redis-ha/templates/redis-haproxy-servicemonitor.yaml +++ b/charts/redis-ha/templates/redis-haproxy-servicemonitor.yaml @@ -23,6 +23,14 @@ spec: {{- end }} {{- if .Values.haproxy.metrics.serviceMonitor.timeout }} scrapeTimeout: {{ .Values.haproxy.metrics.serviceMonitor.timeout }} +{{- end }} +{{- if .Values.haproxy.metrics.serviceMonitor.metricRelabelings }} + metricRelabelings: + {{- toYaml .Values.haproxy.metrics.serviceMonitor.metricRelabelings | nindent 6 }} +{{- end }} +{{- if .Values.haproxy.metrics.serviceMonitor.relabelings }} + relabelings: + {{- toYaml .Values.haproxy.metrics.serviceMonitor.relabelings | nindent 6 }} {{- end }} jobLabel: {{ template "redis-ha.fullname" . }}-haproxy namespaceSelector: diff --git a/charts/redis-ha/values.yaml b/charts/redis-ha/values.yaml index d2c9721..3444b4b 100644 --- a/charts/redis-ha/values.yaml +++ b/charts/redis-ha/values.yaml @@ -142,6 +142,22 @@ haproxy: # labels: {} # Set timeout for scrape # timeout: 10s + # + # RelabelConfigs to apply to samples before scraping. + relabelings: [] + # - sourceLabels: [__meta_kubernetes_pod_node_name] + # separator: ; + # regex: ^(.*)$ + # targetLabel: nodename + # replacement: $1 + # action: replace + + # MetricRelabelConfigs to apply to samples after scraping, but before ingestion. + metricRelabelings: [] + # - action: keep + # regex: 'kube_(daemonset|deployment|pod|namespace|node|statefulset).+' + # sourceLabels: [__name__] + init: resources: {} timeout: @@ -502,6 +518,22 @@ exporter: # Set timeout for scrape # timeout: 10s + # RelabelConfigs to apply to samples before scraping. + relabelings: [] + # - sourceLabels: [__meta_kubernetes_pod_node_name] + # separator: ; + # regex: ^(.*)$ + # targetLabel: nodename + # replacement: $1 + # action: replace + + # MetricRelabelConfigs to apply to samples after scraping, but before ingestion. + metricRelabelings: [] + # - action: keep + # regex: 'kube_(daemonset|deployment|pod|namespace|node|statefulset).+' + # sourceLabels: [__name__] + + # prometheus exporter SCANS redis db which can take some time # allow different probe settings to not let container crashloop livenessProbe: