def printTask(self):
     
     self.runSendMail = self.checkRunSendMail()
     if(self.runSendMail == 1):
         self.cThread = self.manageThread();
         if(self.cThread is not None):
             log.info("Start current Thread %s" %self.cThread.getName())
             self.cThread.showThread() 
     else:
         tgscheduler.stop_scheduler()
         log.info("Server : %s(%s) is not permission run send mail" %s(self.sysServer.server_name, self.sysServer.ip_server))
Beispiel #2
0
def bootstrap(command, conf, vars):
    """Place any commands to setup outages here"""

    #Kill the scheduler
    tgscheduler.stop_scheduler()

    root_node = LocationNode(id=0, name="RootNode", location_level="ROOTNODE")

    DBSession.add(root_node)
    DBSession.flush()

    transaction.commit()
Beispiel #3
0
 def printTask(self):
     
     self.runSendMail = self.checkRunSendMail()
     
     if(self.runSendMail == 1):
         self.SMTP = self.checkSMTPServer()
         
         self.cThread = self.manageThread(smtps = self.SMTP)
         if(self.cThread is not None):
             #log.info("Start current Thread %s" %self.cThread.getName())
             self.cThread.setSMTPs(smtps = self.SMTP)
             self.cThread.showThread() 
     else:
         tgscheduler.stop_scheduler()
Beispiel #4
0
 def tearDown(self):
     stop_scheduler()