mittwald / kubernetes-secret-generator

Kubernetes controller for automatically generating and updating secrets
Apache License 2.0
330 stars 57 forks source link

rewrite using operator-sdk #18

Closed hensur closed 4 years ago

hensur commented 4 years ago

Initially, I just wanted to add a new feature to the operator. This change does much more. While scanning the code base, I noticed, that editing a secret, for example adding a new filed to the list of to-be-generated fields, can lead to the regeneration of every field in the secret.

Also, the error returned by rand.Read wasn't checked.

Furthermore, the client-go used by this project was really old, instead of just bumping the version, I decided it might be better to just rewrite this using the operator-sdk.

I also added some integration tests, to make sure the operator behaves as it's supposed to.