Skip to content
Snippets Groups Projects
Commit 98af4c22 authored by Debora Benedetto's avatar Debora Benedetto
Browse files

bugfix in CompressFolder class

parent 8b0280d4
Branches
No related tags found
No related merge requests found
......@@ -21,6 +21,5 @@ def create_iac_from_doml(data: str = Body(..., media_type="application/xml")):
logging.info("Received create_iac_from_doml request")
compress_folder_info = Orchestrator.create_iac_from_doml(model=data, metamodel_directory="icgparser/doml",
is_multiecore_metamodel=False)
logging.info(f"file_path: {compress_folder_info.file_path}, filename: {compress_folder_info.filename}")
return FileResponse(path=compress_folder_info.filename, media_type='application/octet-stream', ## TODO change path into compress_folder_info.file_path
return FileResponse(path=compress_folder_info.file_path, media_type='application/octet-stream',
filename=compress_folder_info.filename)
......@@ -8,9 +8,10 @@ from plugin import AnsiblePlugin, TerraformPlugin
class CompressFolder:
def __init__(self, file_path, filename):
self.file_path = file_path,
self.file_path = file_path
self.filename = filename
def create_infrastructure_files(intermediate_representation: dict):
template_generated_folder = intermediate_representation["output_path"]
choose_plugin(intermediate_representation, template_generated_folder)
......@@ -98,7 +99,6 @@ def compress_iac_folder(template_generated_folder):
compress_file_folder_path = compress_file(template_generated_folder, compress_file_name)
logging.info(f"Successfully created iac files, available at {compress_file_folder_path}")
compress_folder_info = CompressFolder(file_path=compress_file_folder_path, filename=compress_file_name)
logging.info(f"######################### {compress_folder_info.file_path}") ## TODO fix, is tuple instead of string
return compress_folder_info
def create_iac_from_intermediate_representation(intermediate_representation):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment