Commit 339d401d authored by Alejandro Homs Puron's avatar Alejandro Homs Puron
Browse files

[LIMA_LAUNCHER] Support tango_lima applications

parent 437b20a2
......@@ -148,6 +148,23 @@ def get_tango_json_config(server, instance):
return config_str
def launch_lima_tango(config, args):
tango_config = config.get('lima_tango', {})
instance = tango_config.get('instance', '')
if not instance:
raise ValueError('Missing lima_tango instance definition')
tango_debug_level = config.get('tango_debug_level', None)
environ_config = config.get('environment', {})
with Environment(environ_config, args=args) as env:
cmd = ['LimaCCDs', instance]
if tango_debug_level is not None:
ret = env.run_system_cmd(*cmd)
def lima2_get_executables(tango_config, args):
plugin = tango_config.get('plugin', '')
if not plugin:
......@@ -244,15 +261,18 @@ def main():
config = json.loads(json_config)
if args.verbose:
print('JSON config:')
config = json.loads(json_config)
os.environ['LIMA_LAUNCHER_PID'] = str(os.getpid())
app = config.get('application', '')
if app == 'lima2_tango':
if app == 'lima_tango':
launch_lima_tango(config, args)
elif app == 'lima2_tango':
launch_lima2_tango(config, args)
raise ValueError('Only lima2_tango application supported')
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment