Commit 9773acfa authored by Alain Takoudjou's avatar Alain Takoudjou

Allow to set debug mode in slaprunner-instance profile

parent 83e552f0
...@@ -72,7 +72,7 @@ class Recipe(GenericBaseRecipe): ...@@ -72,7 +72,7 @@ class Recipe(GenericBaseRecipe):
private_key=self.options['private_key'], private_key=self.options['private_key'],
cloud9_url=self.cloud9_url cloud9_url=self.cloud9_url
) )
config_file = self.createFile(self.options['slapos.cfg'], config_file = self.createFile(self.options['slapos.cfg'],
self.substituteTemplate(self.getTemplateFilename('slapos.cfg.in'), self.substituteTemplate(self.getTemplateFilename('slapos.cfg.in'),
configuration)) configuration))
...@@ -82,8 +82,9 @@ class Recipe(GenericBaseRecipe): ...@@ -82,8 +82,9 @@ class Recipe(GenericBaseRecipe):
PATH=os.path.dirname(self.options['git-binary']) + ':' + os.environ['PATH'], PATH=os.path.dirname(self.options['git-binary']) + ':' + os.environ['PATH'],
GIT_SSH=self.options['ssh_client'] GIT_SSH=self.options['ssh_client']
) )
launch_args = [self.options['slaprunner'].strip(), config_file]
launch_args = [self.options['slaprunner'].strip(), config_file, '--debug'] if self.optionIsTrue('debug', default=False):
launch_args.append('--debug')
wrapper = self.createPythonScript(self.options['wrapper'], wrapper = self.createPythonScript(self.options['wrapper'],
'slapos.recipe.librecipe.execute.executee', 'slapos.recipe.librecipe.execute.executee',
......
Markdown is supported
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