Valkey Sentinel: Fixing Auth/ACL gaps in TLS environments and security hardening (Enhancements for PR #137)#1
Conversation
fix(chart): resolve schema validation and template errors
- Updating HAProxy watcher for near-instant IP-based failover. - Refactoring init scripts to support dynamic topology and universal auth/TLS injection. - Adding smart L7 health checks in HAProxy to handle ACL-protected nodes. - Fully parameterizing Service and ConfigMap ports for end-to-end flexibility.
|
Hi @khtee, Following my initial comments on this PR, I have pushed an update to stabilize the Sentinel High Availability architecture. After testing in environments (with TLS and ACLs enabled), I’ve identified and fixed several edge cases where the cluster would fail to recover during failovers. Here is a summary of the key improvements included in this update: 1. Sentinel-Aware Topology Management (
|
…notations in haproxy-deployment
|
Hey! I've updated this branch with the correct DCO sign-offs and fixed the author email. Since you already merged the previous version, you need to force-push my new changes into your branch to clear the DCO error in the main PR. You can do this by running: Have a nice day |
Hi @khtee,
Your implementation of Sentinel in PR valkey-io#137 is a great addition to the chart. However, during testing in secured environments, I found that the stack encounters critical issues when the default user is disabled (a common security requirement).
Without these fixes, Sentinels are unable to discover each other or the master in Auth+TLS scenarios (the "empty array" issue). This PR addresses those gaps and introduces several security hardening measures and schema fixes to make the implementation production-ready.
Key Improvements & Bug Fixes
1. Security & ACL Logic (Auth + TLS Interop)
sentinel-userandsentinel-pass. This is the missing link that allows Sentinels to form a quorum and gossip when TLS and ACLs are both active.monitorUserfor Sentinel-to-Valkey communication. This allows separating the Replication User (sync only) from the Monitor User (Pub/Sub and health), following the principle of least privilege.auth-userandsentinel-userwhen the user isdefault, preventing fatal config errors.defaultuser (off resetchannels -@all) without breaking cluster discovery.2. Credential Protection & Logging
cat "$SENTINEL_CONF"command from the init script to prevent passwords from being exposed in Kubernetes logs.log()function to output tostderr(>&2). This prevents log messages from polluting command substitutions or leaking sensitive data into configuration files.3. Helm Schema & Configuration Fixes
values.schema.jsonand added thesentinelAclUsersdefinition to pass validation.2.9) to a string ("2.9") invalues.yaml, fixing YAML parsing errors and ensuringhelm lintpasses.Testing Status
kubectl logs.