diff --git a/src/aosm/azext_aosm/configuration_models/onboarding_vnf_input_config.py b/src/aosm/azext_aosm/configuration_models/onboarding_vnf_input_config.py index 97f52dea77f..f017f508c8e 100644 --- a/src/aosm/azext_aosm/configuration_models/onboarding_vnf_input_config.py +++ b/src/aosm/azext_aosm/configuration_models/onboarding_vnf_input_config.py @@ -147,10 +147,6 @@ def __post_init__(self): if self.vhd and isinstance(self.vhd, dict): self.vhd = VhdImageConfig(**self.vhd) - sanitized_nf_name = self.nf_name.lower().replace("_", "-") - if not self.blob_artifact_store_name: - self.blob_artifact_store_name = sanitized_nf_name + "-sa" - @property def sa_manifest_name(self) -> str: """Return the Storage account manifest name from the NFD name and version.""" @@ -172,6 +168,11 @@ def validate(self): arm_template.validate() self.vhd.validate() + # We have to do this in validate, otherwise it created the input file with "-sa" + sanitized_nf_name = self.nf_name.lower().replace("_", "-") + if not self.blob_artifact_store_name: + self.blob_artifact_store_name = sanitized_nf_name + "-sa" + @dataclass class OnboardingNexusVNFInputConfig(OnboardingNFDBaseInputConfig):