feat(operator): add ACL watcher sidecar image#478
feat(operator): add ACL watcher sidecar image#478rkthtrifork wants to merge 5 commits intodragonflydb:mainfrom
Conversation
|
Alternative implementation: small Go binary that does the same and runs in a distroless container for improved security. I have already implemented that locally and would like to use it if you agree it is sensible EDIT: I have done this because i think its more production ready and it was a fairly small change |
|
Hi @rkthtrifork, having a separate acl watcher sidecar sounds like overdoing. Have you considered extending the reconciler to do so? |
I considered it, but the mounted ACL file is updated asynchronously by kubernetes. If the controller watches the secret then it will trigger immediately which will usually be before the mounted ACL file has updated. Alternatively, the controller should watch the secret and apply the changes through the dragonfly API, but then its not the mounted file thats the source of truth anymore which creates the problem of drift. Im not a fan of that. |
…decar # Conflicts: # internal/resources/const.go
Summary
spec.aclFromSecretis configured.Motivation
Mounted Secret updates are eventually consistent. The sidecar watches the ACL file and runs
ACL LOADafter the file actually changes.Notes
spec.authentication.passwordFromSecretis not automatically updated since its inject through an environment variable. It could make sense to document this and recommend useaclFromSecretif possible.Testing
Issue
#479