add sea config information to sea list
+ fixed servman import (must be __init__)
This commit is contained in:
15
__init__.py
15
__init__.py
@ -154,12 +154,12 @@ class ServiceManager:
|
||||
self.get_info()
|
||||
return self.info[ins]
|
||||
|
||||
#def get_cfg(self, service, cmd):
|
||||
# """return info about running program, if relevant
|
||||
#
|
||||
# example for frappy: return cfg
|
||||
# """
|
||||
# return ''
|
||||
def get_cfg(self, service):
|
||||
"""return cfg info about running programs, if relevant
|
||||
|
||||
example for sea: return samenv name
|
||||
"""
|
||||
return ''
|
||||
|
||||
def get_procs(self, groups=None, cfginfo=None):
|
||||
"""return processes
|
||||
@ -364,11 +364,12 @@ class ServiceManager:
|
||||
for serv, port in info_grp.items():
|
||||
plist = procs_dict.get(serv)
|
||||
if plist:
|
||||
cfg = cfginfo.get((ins_i, serv), '') or sm.get_cfg(serv)
|
||||
if sm == self:
|
||||
show_ins = True
|
||||
gs = '%s %s' % (group, serv)
|
||||
port = str(port or '')
|
||||
run_info.append(('', gs, port, cfginfo.get((ins_i, serv), '')))
|
||||
run_info.append(('', gs, port, cfg))
|
||||
if len(plist) > 1:
|
||||
rows.append(['', ' WARNING: multiple processes %s'
|
||||
% ', '.join(str(p.pid) for p, _ in plist)])
|
||||
|
Reference in New Issue
Block a user