Skip to content

Commit

Permalink
fix vnf deploy schema types (Azure#44)
Browse files Browse the repository at this point in the history
  • Loading branch information
sunnycarter authored Jul 7, 2023
1 parent 21154ff commit a299eba
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/aosm/azext_aosm/generate_nfd/vnf_nfd_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@
# https://microsoft.sharepoint.com/:w:/t/NSODevTeam/Ec7ovdKroSRIv5tumQnWIE0BE-B2LykRcll2Qb9JwfVFMQ
ARM_TO_JSON_PARAM_TYPES: Dict[str, str] = {
"int": "integer",
"secureString": "string",
"securestring": "string",
"bool": "boolean",
}


Expand Down Expand Up @@ -197,7 +198,7 @@ def write_deployment_parameters(self, directory: Path) -> None:

# Map ARM parameter types to JSON parameter types accepted by AOSM
arm_type = self.vm_parameters[key]["type"]
json_type = ARM_TO_JSON_PARAM_TYPES.get(arm_type, arm_type)
json_type = ARM_TO_JSON_PARAM_TYPES.get(arm_type.lower(), arm_type)

if has_default:
nfd_parameters_with_default[key] = {"type": json_type}
Expand Down

0 comments on commit a299eba

Please sign in to comment.