added python
This commit is contained in:
parent
5f382da83b
commit
863ea67d06
2 changed files with 11 additions and 5 deletions
|
|
@ -16,7 +16,7 @@ VERSION = "0.1"
|
|||
class LishFrontend(Frontend):
|
||||
def __init__(self, **kwargs):
|
||||
|
||||
print(kwargs)
|
||||
#print(kwargs)
|
||||
#self.jobs = kwargs["jobs"]
|
||||
|
||||
commander = LishCommander(kwargs)
|
||||
|
|
@ -150,6 +150,16 @@ class LishCommander(Exit, ShellCommander, LogCommander):
|
|||
except KeyboardInterrupt, ke:
|
||||
pass
|
||||
|
||||
def do_python(self, text):
|
||||
exec text
|
||||
|
||||
def help_python(self):
|
||||
print '''
|
||||
executes python using 'exec'.
|
||||
'''
|
||||
|
||||
|
||||
|
||||
|
||||
def help_hostgroup(self):
|
||||
print '''
|
||||
|
|
|
|||
|
|
@ -62,8 +62,6 @@ def main():
|
|||
scheduler.start()
|
||||
jobs = []
|
||||
|
||||
|
||||
|
||||
for layout in linConf.get_enabled_layouts():
|
||||
for hostgroup in layout.get_hostgroups():
|
||||
for service in hostgroup.get_services():
|
||||
|
|
@ -81,8 +79,6 @@ def main():
|
|||
log.d("shutting down scheduler")
|
||||
scheduler.shutdown(wait=False)
|
||||
|
||||
|
||||
|
||||
elif args.action == "stop":
|
||||
log.i("stopping linspector is currently unsupported")
|
||||
elif args.action == "restart":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue