Skip to content

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,9 @@ class Delete(AAZCommand):
"""

_aaz_info = {
"version": "2026-04-01-preview",
"version": "2026-08-01",
"resources": [
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}", "2026-04-01-preview"],
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}", "2026-08-01"],
]
}

Expand Down Expand Up @@ -147,7 +147,7 @@ def url_parameters(self):
def query_parameters(self):
parameters = {
**self.serialize_query_param(
"api-version", "2026-04-01-preview",
"api-version", "2026-08-01",
required=True,
),
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,10 +23,10 @@ class List(AAZCommand):
"""

_aaz_info = {
"version": "2026-04-01-preview",
"version": "2026-08-01",
"resources": [
["mgmt-plane", "/subscriptions/{}/providers/microsoft.azurefleet/fleets", "2026-04-01-preview"],
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets", "2026-04-01-preview"],
["mgmt-plane", "/subscriptions/{}/providers/microsoft.azurefleet/fleets", "2026-08-01"],
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets", "2026-08-01"],
]
}

Expand All @@ -52,12 +52,12 @@ def _build_arguments_schema(cls, *args, **kwargs):

def _execute_operations(self):
self.pre_operations()
condition_0 = has_value(self.ctx.args.resource_group) and has_value(self.ctx.subscription_id)
condition_1 = has_value(self.ctx.subscription_id) and has_value(self.ctx.args.resource_group) is not True
condition_0 = has_value(self.ctx.subscription_id) and has_value(self.ctx.args.resource_group) is not True
condition_1 = has_value(self.ctx.args.resource_group) and has_value(self.ctx.subscription_id)
if condition_0:
self.FleetsListByResourceGroup(ctx=self.ctx)()
if condition_1:
self.FleetsListBySubscription(ctx=self.ctx)()
if condition_1:
self.FleetsListByResourceGroup(ctx=self.ctx)()
self.post_operations()

@register_callback
Expand All @@ -73,7 +73,7 @@ def _output(self, *args, **kwargs):
next_link = self.deserialize_output(self.ctx.vars.instance.next_link)
return result, next_link

class FleetsListByResourceGroup(AAZHttpOperation):
class FleetsListBySubscription(AAZHttpOperation):
CLIENT_TYPE = "MgmtClient"

def __call__(self, *args, **kwargs):
Expand All @@ -87,7 +87,7 @@ def __call__(self, *args, **kwargs):
@property
def url(self):
return self.client.format_url(
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureFleet/fleets",
"/subscriptions/{subscriptionId}/providers/Microsoft.AzureFleet/fleets",
**self.url_parameters
)

Expand All @@ -102,10 +102,6 @@ def error_format(self):
@property
def url_parameters(self):
parameters = {
**self.serialize_url_param(
"resourceGroupName", self.ctx.args.resource_group,
required=True,
),
**self.serialize_url_param(
"subscriptionId", self.ctx.subscription_id,
required=True,
Expand All @@ -117,7 +113,7 @@ def url_parameters(self):
def query_parameters(self):
parameters = {
**self.serialize_query_param(
"api-version", "2026-04-01-preview",
"api-version", "2026-08-01",
required=True,
),
}
Expand Down Expand Up @@ -271,9 +267,6 @@ def _build_schema_on_200(cls):
serialized_name="vmSizesProfile",
flags={"required": True},
)
properties.zone_allocation_policy = AAZObjectType(
serialized_name="zoneAllocationPolicy",
)

additional_locations_profile = cls._schema_on_200.value.Element.properties.additional_locations_profile
additional_locations_profile.location_profiles = AAZListType(
Expand Down Expand Up @@ -445,24 +438,6 @@ def _build_schema_on_200(cls):
)
_element.rank = AAZIntType()

zone_allocation_policy = cls._schema_on_200.value.Element.properties.zone_allocation_policy
zone_allocation_policy.distribution_strategy = AAZStrType(
serialized_name="distributionStrategy",
flags={"required": True},
)
zone_allocation_policy.zone_preferences = AAZListType(
serialized_name="zonePreferences",
)

zone_preferences = cls._schema_on_200.value.Element.properties.zone_allocation_policy.zone_preferences
zone_preferences.Element = AAZObjectType()

_element = cls._schema_on_200.value.Element.properties.zone_allocation_policy.zone_preferences.Element
_element.rank = AAZIntType()
_element.zone = AAZStrType(
flags={"required": True},
)

system_data = cls._schema_on_200.value.Element.system_data
system_data.created_at = AAZStrType(
serialized_name="createdAt",
Expand Down Expand Up @@ -491,7 +466,7 @@ def _build_schema_on_200(cls):

return cls._schema_on_200

class FleetsListBySubscription(AAZHttpOperation):
class FleetsListByResourceGroup(AAZHttpOperation):
CLIENT_TYPE = "MgmtClient"

def __call__(self, *args, **kwargs):
Expand All @@ -505,7 +480,7 @@ def __call__(self, *args, **kwargs):
@property
def url(self):
return self.client.format_url(
"/subscriptions/{subscriptionId}/providers/Microsoft.AzureFleet/fleets",
"/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureFleet/fleets",
**self.url_parameters
)

Expand All @@ -520,6 +495,10 @@ def error_format(self):
@property
def url_parameters(self):
parameters = {
**self.serialize_url_param(
"resourceGroupName", self.ctx.args.resource_group,
required=True,
),
**self.serialize_url_param(
"subscriptionId", self.ctx.subscription_id,
required=True,
Expand All @@ -531,7 +510,7 @@ def url_parameters(self):
def query_parameters(self):
parameters = {
**self.serialize_query_param(
"api-version", "2026-04-01-preview",
"api-version", "2026-08-01",
required=True,
),
}
Expand Down Expand Up @@ -685,9 +664,6 @@ def _build_schema_on_200(cls):
serialized_name="vmSizesProfile",
flags={"required": True},
)
properties.zone_allocation_policy = AAZObjectType(
serialized_name="zoneAllocationPolicy",
)

additional_locations_profile = cls._schema_on_200.value.Element.properties.additional_locations_profile
additional_locations_profile.location_profiles = AAZListType(
Expand Down Expand Up @@ -859,24 +835,6 @@ def _build_schema_on_200(cls):
)
_element.rank = AAZIntType()

zone_allocation_policy = cls._schema_on_200.value.Element.properties.zone_allocation_policy
zone_allocation_policy.distribution_strategy = AAZStrType(
serialized_name="distributionStrategy",
flags={"required": True},
)
zone_allocation_policy.zone_preferences = AAZListType(
serialized_name="zonePreferences",
)

zone_preferences = cls._schema_on_200.value.Element.properties.zone_allocation_policy.zone_preferences
zone_preferences.Element = AAZObjectType()

_element = cls._schema_on_200.value.Element.properties.zone_allocation_policy.zone_preferences.Element
_element.rank = AAZIntType()
_element.zone = AAZStrType(
flags={"required": True},
)

system_data = cls._schema_on_200.value.Element.system_data
system_data.created_at = AAZStrType(
serialized_name="createdAt",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@ class ListVms(AAZCommand):
"""

_aaz_info = {
"version": "2026-04-01-preview",
"version": "2026-08-01",
"resources": [
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}/virtualmachines", "2026-04-01-preview"],
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}/virtualmachines", "2026-08-01"],
]
}

Expand Down Expand Up @@ -138,7 +138,7 @@ def query_parameters(self):
"$skiptoken", self.ctx.args.skiptoken,
),
**self.serialize_query_param(
"api-version", "2026-04-01-preview",
"api-version", "2026-08-01",
required=True,
),
}
Expand Down Expand Up @@ -195,9 +195,19 @@ def _build_schema_on_200(cls):
serialized_name="operationStatus",
flags={"read_only": True},
)
_element.priority = AAZStrType(
flags={"read_only": True},
)
_element.type = AAZStrType(
flags={"read_only": True},
)
_element.vm_size = AAZStrType(
serialized_name="vmSize",
flags={"read_only": True},
)
_element.zone = AAZStrType(
flags={"read_only": True},
)

error = cls._schema_on_200.value.Element.error
error.code = AAZStrType()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ class ListVmss(AAZCommand):
"""

_aaz_info = {
"version": "2026-04-01-preview",
"version": "2026-08-01",
"resources": [
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}/virtualmachinescalesets", "2026-04-01-preview"],
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}/virtualmachinescalesets", "2026-08-01"],
]
}

Expand Down Expand Up @@ -125,7 +125,7 @@ def url_parameters(self):
def query_parameters(self):
parameters = {
**self.serialize_query_param(
"api-version", "2026-04-01-preview",
"api-version", "2026-08-01",
required=True,
),
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ class Show(AAZCommand):
"""

_aaz_info = {
"version": "2026-04-01-preview",
"version": "2026-08-01",
"resources": [
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}", "2026-04-01-preview"],
["mgmt-plane", "/subscriptions/{}/resourcegroups/{}/providers/microsoft.azurefleet/fleets/{}", "2026-08-01"],
]
}

Expand Down Expand Up @@ -124,7 +124,7 @@ def url_parameters(self):
def query_parameters(self):
parameters = {
**self.serialize_query_param(
"api-version", "2026-04-01-preview",
"api-version", "2026-08-01",
required=True,
),
}
Expand Down Expand Up @@ -267,9 +267,6 @@ def _build_schema_on_200(cls):
serialized_name="vmSizesProfile",
flags={"required": True},
)
properties.zone_allocation_policy = AAZObjectType(
serialized_name="zoneAllocationPolicy",
)

additional_locations_profile = cls._schema_on_200.properties.additional_locations_profile
additional_locations_profile.location_profiles = AAZListType(
Expand Down Expand Up @@ -441,24 +438,6 @@ def _build_schema_on_200(cls):
)
_element.rank = AAZIntType()

zone_allocation_policy = cls._schema_on_200.properties.zone_allocation_policy
zone_allocation_policy.distribution_strategy = AAZStrType(
serialized_name="distributionStrategy",
flags={"required": True},
)
zone_allocation_policy.zone_preferences = AAZListType(
serialized_name="zonePreferences",
)

zone_preferences = cls._schema_on_200.properties.zone_allocation_policy.zone_preferences
zone_preferences.Element = AAZObjectType()

_element = cls._schema_on_200.properties.zone_allocation_policy.zone_preferences.Element
_element.rank = AAZIntType()
_element.zone = AAZStrType(
flags={"required": True},
)

system_data = cls._schema_on_200.system_data
system_data.created_at = AAZStrType(
serialized_name="createdAt",
Expand Down
Loading
Loading