def restart_local(name, drain=False):
 ret = {'name': name, 'changes': {}, 'result': None, 'comment': ''}
 if __opts__['test']:
  ret['comment'] = 'Restarting local node'
  return ret
 if drain:
  __salt__['trafficserver.restart_local'](drain=True)
  ret['result'] = True
  ret['comment'] = 'Restarted local node with drain option'
  return ret
 else:
  __salt__['trafficserver.restart_local']()
  ret['result'] = True
  ret['comment'] = 'Restarted local node'
  return ret

def restart_local ( name , drain = False ) : ret = { 'name' : name , 'changes' : { } , 'result' : None , 'comment' : '' } if __opts__ [ 'test' ] : ret [ 'comment' ] = 'Restarting local node' return ret if drain : __salt__ [ 'trafficserver.restart_local' ] ( drain = True ) ret [ 'result' ] = True ret [ 'comment' ] = 'Restarted local node with drain option' return ret else : __salt__ [ 'trafficserver.restart_local' ] ( ) ret [ 'result' ] = True ret [ 'comment' ] = 'Restarted local node' return ret
restart the traffic_manager and traffic_server processes on the local node .