Why check if redis user exists?
eRadical opened this issue · 1 comments
What is the rationale behing checking for user existence?
ansible-redis/tasks/install.yml
Lines 27 to 47 in 0b5887b
The when clause from user creation should simply go away.
Instead of interpreting it as "make user redis if not exists" that should be read/seen as "make sure user redis exists"... more inclined to the state of things rather than action.
Same goes for the redis group which is now checked through the existence of the user.
[Would be glad to make a pull request on this but I wanted to see if there is any rationale that I missed.]
I haven't looked at this in a while, but I think the logic here was to prevent changes to an already existing redis user. If you look at the original commit there's mention of a failure when running usermod in that case.