-
Notifications
You must be signed in to change notification settings - Fork 210
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[rabbitmq] Remove guest user by default #1420
Conversation
594108f
to
f3c880f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good -- I'd prefer one call to rmqctl less if possible, but don't worry about that if it's not simple 😉
execute "#{rmq_ctl} delete_user guest" do | ||
environment (rabbitmq_env) | ||
user opc_username | ||
only_if "#{rmq_ctl} list_users| grep guest", :environment => rabbitmq_env |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What would happen if we executed this unconditionally? Delete might be idempotent? Just wondering if we can save us a call to rabbitmqctl
, since these are quite expensive 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like we can save that call, changes made! thank you :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm have you pushed that? My expectation -- if we can save a call -- would be to have this block as
execute "#{rmq_ctl} delete_user guest" do
environment (rabbitmq_env)
user opc_username
end
So, no only_if
at all. Does that make sense? 😉
f3c880f
to
ce076fc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
ce076fc
to
44ac9f3
Compare
Signed-off-by: Prajakta Purohit <[email protected]>
44ac9f3
to
6ab5bc7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me with or without the change @srenatus recommended.
No description provided.