def vhost_exists(name, runas=None):
    if runas is None:
        runas = salt.utils.get_user()
    return name in list_vhosts(runas=runas)
Return whether the vhost exists based on rabbitmqctl list_vhosts.
dataset/ETHPy150Open saltstack/salt/salt/modules/rabbitmq.py/vhost_exists