in source/lib/ssm.py [0:0]
def create_command(self, replace_dict):
try:
lines=[]
src_dir = os.path.dirname(os.path.abspath(__file__))
self.logger.debug('Abs path: {}'.format(src_dir))
f = 'ssm.sh'
with open(os.path.join(src_dir, f)) as file:
for line in file:
for src, target in replace_dict.items():
line = line.replace(src, target)
lines.append(line)
return lines
except Exception as e:
self.logger.error("unhandled exception: SimpleSystemsManager_create_command", exc_info=1)