docs: def alias(name, collections, **kwargs):
      '''
      Create alias and enforce collection list.
  
      Use the solrcloud module to get alias members and set them.
  
      You can pass additional arguments that will be forwarded to http.query
  
      name
          The collection name
      collections
          list of collections to include in the alias
      '''
      ret = {
          'name': name,
          'changes': {},
          'result': False,
          'comment': '',
      }
  
      if __salt__['solrcloud.alias_exists'](name, **kwargs):
          alias_content = __salt__['solrcloud.alias_get_collections'](name, **kwargs)
          diff = set(alias_content).difference(set(collections))
  
          if not diff:
              ret['result'] = True
              ret['comment'] = 'Alias is in desired state'
              return ret
  
          if __opts__['test']:
              ret['comment'] = 'The alias "{0}" will be updated.'.format(name)
              ret['result'] = None
          else:
              __salt__['solrcloud.alias_set_collections'](name, collections, **kwargs)
              ret['comment'] = 'The alias "{0}" has been updated.'.format(name)
              ret['result'] = True
  
          ret['changes'] = {
              'old': ','.join(alias_content),
              'new': ','.join(collections),
          }
  
      else:
          if __opts__['test']:
              ret['comment'] = 'The alias "{0}" will be created.'.format(name)
              ret['result'] = None
          else:
              __salt__['solrcloud.alias_set_collections'](name, collections, **kwargs)
              ret['comment'] = 'The alias "{0}" has been created.'.format(name)
              ret['result'] = True
  
          ret['changes'] = {
              'old': None,
              'new': ','.join(collections),
          }
  
      return ret