def ch_config(cmd, *args, **kwargs):
 for k in kwargs.keys():
  if k.startswith('__pub_'):
   kwargs.pop(k)
 kwargs['host'] = DETAILS['host']
 kwargs['username'] = DETAILS['username']
 kwargs['password'] = DETAILS['password']
 kwargs['port'] = DETAILS['port']
 kwargs['protocol'] = DETAILS['protocol']
 if (('vsphere.' + cmd) not in __salt__):
  return {'retcode': (-1), 'message': (('vsphere.' + cmd) + ' is not available.')}
 else:
  return __salt__[('vsphere.' + cmd)](*args, **kwargs)

def ch_config ( cmd , * args , ** kwargs ) : for k in kwargs . keys ( ) : if k . startswith ( '__pub_' ) : kwargs . pop ( k ) kwargs [ 'host' ] = DETAILS [ 'host' ] kwargs [ 'username' ] = DETAILS [ 'username' ] kwargs [ 'password' ] = DETAILS [ 'password' ] kwargs [ 'port' ] = DETAILS [ 'port' ] kwargs [ 'protocol' ] = DETAILS [ 'protocol' ] if ( ( 'vsphere.' + cmd ) not in __salt__ ) : return { 'retcode' : ( - 1 ) , 'message' : ( ( 'vsphere.' + cmd ) + ' is not available.' ) } else : return __salt__ [ ( 'vsphere.' + cmd ) ] ( * args , ** kwargs )
this function is called by the :mod:salt .