Fix RabbitMQ tags not properly set.

This commit is contained in:
NLR 2017-08-02 17:50:02 +02:00
parent f2b0c9b4fa
commit 287b57b5c5

View file

@ -472,11 +472,11 @@ def set_user_tags(name, tags, runas=None):
if runas is None:
runas = salt.utils.get_user()
if tags and isinstance(tags, (list, tuple)):
tags = ' '.join(tags)
if not isinstance(tags, (list, tuple)):
tags = [tags]
res = __salt__['cmd.run'](
['rabbitmqctl', 'set_user_tags', name, tags],
['rabbitmqctl', 'set_user_tags', name] + tags,
runas=runas,
python_shell=False)
msg = "Tag(s) set"