Export and scrape metrics from all redis/valkey instances #398
Reference in New Issue
Block a user
Delete Branch "benvin/redis-metrics"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Why
No redis/valkey instance managed in this repo exports metrics today — the six caches (artifactapi, authentik, litellm, gitea, netbox, jellyfin) are blind spots in VictoriaMetrics.
What
exporter.enabled: true); overrides the operator's default bare-dockerhub image (oliver006/redis_exporter:v1.80.0) with the artifactapi-proxied pin. The operator manages a dedicated_exporterACL user for it.metrics-exportersidecar (artifactapi.k8s.syd1.au.unkin.net/dockerhub/oliver006/redis_exporter:v1.89.0, :9121, port namemetrics, req 32Mi/25m lim 64Mi/100m) to the five raw Deployments: artifactapi/authentik/litellm redis and gitea/netbox valkey. gitea/netbox sidecars get the same restrictive securityContext as their valkey container.monitoring.unkin.net/redis-exporter: "true"opt-in pod label to all five pod templates.apps/base/observability/vmpodscrape-redis.yamlwith two VMPodScrapes (any namespace, portmetrics):redis-exportersselecting the opt-in label, andvalkey-operator-clustersselectingapp.kubernetes.io/managed-by: valkey-operator+app.kubernetes.io/component: valkey-node— the ValkeyCluster CR has no pod-label passthrough (verified against the v0.5.0 CRD/source), so operator pods cannot carry the opt-in label.Notes
requirepass/auth, so no REDIS_PASSWORD wiring is needed on the raw Deployments; the jellyfin exporter auth is operator-managed.kustomize buildon every touched base + au-syd1 overlay (helm overlays with--enable-helm) andkubeconform -strict -ignore-missing-schemas(68 valid, 0 invalid).Reworked per review in
9b154d3: dropped the shared label-selector approach in favour of explicit per-app scrape objects.monitoring.unkin.net/redis-exporteropt-in pod label from all 5 raw deployments (artifactapi/authentik/litellm redis, gitea/netbox valkey); exporter sidecars unchangedapps/base/observability/vmpodscrape-redis.yaml(both cross-namespace scrapes) and its kustomization entryvmpodscrape.yamlin each app's own base dir, mirroring the arrstack exportarr pattern: local-namespace selector on the deployment's existing pod labels (app: redis/app: gitea-valkey/app: netbox-valkey), portmetrics, path/metricsapps/base/jellyfinselecting the valkey-operator node labels (app.kubernetes.io/managed-by: valkey-operator+app.kubernetes.io/component: valkey-node)exporter.enabled+ image override are unchangedValidated:
kustomize build(incl.--enable-helmoverlays) for all 7 touched apps' base + au-syd1, kubeconform clean with the CI schema locations.