@@ -675,13 +675,14 @@ def load_policy_from_arm_template_str(
675675 containers = []
676676 existing_containers = None
677677 fragments = None
678- exclude_default_fragments = False
678+ group_exclude_default_fragments = exclude_default_fragments
679679
680680 tags = case_insensitive_dict_get (resource , config .ACI_FIELD_TEMPLATE_TAGS )
681681 if tags :
682- exclude_default_fragments = case_insensitive_dict_get (tags , config .ACI_FIELD_TEMPLATE_ZERO_SIDECAR )
683- if isinstance (exclude_default_fragments , str ):
684- exclude_default_fragments = exclude_default_fragments .lower () == "true"
682+ group_exclude_default_fragments = \
683+ case_insensitive_dict_get (tags , config .ACI_FIELD_TEMPLATE_ZERO_SIDECAR )
684+ if isinstance (group_exclude_default_fragments , str ):
685+ group_exclude_default_fragments = group_exclude_default_fragments .lower () == "true"
685686
686687 container_group_properties = case_insensitive_dict_get (
687688 resource , config .ACI_FIELD_TEMPLATE_PROPERTIES
@@ -720,7 +721,10 @@ def load_policy_from_arm_template_str(
720721 else :
721722 existing_containers , fragments = ([], [])
722723
723- rego_fragments = copy .deepcopy (config .DEFAULT_REGO_FRAGMENTS ) if not exclude_default_fragments else []
724+ rego_fragments = (
725+ copy .deepcopy (config .DEFAULT_REGO_FRAGMENTS )
726+ if not group_exclude_default_fragments else []
727+ )
724728 if infrastructure_svn :
725729 # assumes the first DEFAULT_REGO_FRAGMENT is always the
726730 # infrastructure fragment
0 commit comments