def _run_server(self):
     #try:
         #pid = local('ps -C node | grep log.io-server | cut -d" " -f6', capture=True)
     #except:
     if not is_running(local, 'log.io-server'):
         with shell_env(NODE_PATH=self.node_path):
             local('log.io-server')
Exemple #2
0
 def _run_server(self):
     #try:
     #pid = local('ps -C node | grep log.io-server | cut -d" " -f6', capture=True)
     #except:
     if not is_running(local, 'log.io-server'):
         with shell_env(NODE_PATH=self.node_path):
             local('log.io-server')
 def _run_harvester(self):
     #time.sleep(10)
     #NOTE I could run it on local as well to inspect report files
     #run('rm /home/xavier/.quantrade/log/*')
     if env.host == utils.get_local_ip():
         local('cp {}/{}-harvester.conf /home/{}/.log.io/harvester.conf'.format(
             self.templates_path, env.host, env.user))
         is_running(local, 'log.io-harvester', kill=True)
         with shell_env(NODE_PATH=self.node_path):
             with hide('output'):
                 local('log.io-harvester')
     else:
         local('scp {}/{}-harvester.conf {}@{}:.log.io/harvester.conf'.format(
             self.templates_path, env.host, env.user, env.host))
         is_running(run, 'log.io-harvester', kill=True)
         with shell_env(NODE_PATH=self.node_path):
             with hide('output'):
                 run('log.io-harvester')
Exemple #4
0
 def _run_harvester(self):
     #time.sleep(10)
     #NOTE I could run it on local as well to inspect report files
     #run('rm /home/xavier/.quantrade/log/*')
     if env.host == utils.get_local_ip():
         local('cp {}/{}-harvester.conf /home/{}/.log.io/harvester.conf'.
               format(self.templates_path, env.host, env.user))
         is_running(local, 'log.io-harvester', kill=True)
         with shell_env(NODE_PATH=self.node_path):
             with hide('output'):
                 local('log.io-harvester')
     else:
         local(
             'scp {}/{}-harvester.conf {}@{}:.log.io/harvester.conf'.format(
                 self.templates_path, env.host, env.user, env.host))
         is_running(run, 'log.io-harvester', kill=True)
         with shell_env(NODE_PATH=self.node_path):
             with hide('output'):
                 run('log.io-harvester')