@@ -15,16 +15,16 @@ Create a Fleet.
1515### CreateExpanded (Default)
1616```
1717New-AzFleet -Name <String> -ResourceGroupName <String> -Location <String> [-SubscriptionId <String>]
18- [-IfMatch <String>] [-IfNoneMatch <String>] [-IdentityType <String> ] [-Tag <Hashtable>]
19- [-UserAssignedIdentity <Hashtable >] [-DefaultProfile <PSObject>] [-AsJob] [-NoWait] [-Confirm] [-WhatIf]
18+ [-IfMatch <String>] [-IfNoneMatch <String>] [-EnableSystemAssignedIdentity ] [-Tag <Hashtable>]
19+ [-UserAssignedIdentity <String[] >] [-DefaultProfile <PSObject>] [-AsJob] [-NoWait] [-Confirm] [-WhatIf]
2020 [<CommonParameters>]
2121```
2222
2323### CreateViaIdentityExpanded
2424```
2525New-AzFleet -InputObject <IFleetIdentity> -Location <String> [-IfMatch <String>] [-IfNoneMatch <String>]
26- [-IdentityType <String> ] [-Tag <Hashtable>] [-UserAssignedIdentity <Hashtable>] [-DefaultProfile <PSObject >]
27- [-AsJob] [-NoWait] [-Confirm] [-WhatIf] [<CommonParameters>]
26+ [-EnableSystemAssignedIdentity ] [-Tag <Hashtable>] [-UserAssignedIdentity <String[] >]
27+ [-DefaultProfile <PSObject>] [- AsJob] [-NoWait] [-Confirm] [-WhatIf] [<CommonParameters>]
2828```
2929
3030### CreateViaJsonFilePath
@@ -46,7 +46,7 @@ Create a Fleet.
4646
4747## EXAMPLES
4848
49- ### Example 1: Creates a Fleet resource
49+ ### Example 1: Creates a Fleet resource with none identity type
5050``` powershell
5151New-AzFleet -Name sss -ResourceGroupName ps1-test -Location eastus
5252```
@@ -74,6 +74,73 @@ Tag : {
7474Type : Microsoft.ContainerService/fleets
7575```
7676
77+ This command creates a Fleet resource with none identity type.
78+
79+ ### Example 2: Creates a Fleet resource with EnableSystemAssignedIdentity
80+ ``` powershell
81+ New-AzFleet -Name testfleet02 -ResourceGroupName joyer-test -Location eastus -Tag @{"456"="asd"} -EnableSystemAssignedIdentity
82+ ```
83+
84+ ``` output
85+ ETag : "0a006dc9-0000-0100-0000-661cd4f70000"
86+ Id : /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/joyer-test/providers/Microsoft.ContainerService/fleets/testfleet02
87+ IdentityPrincipalId : 978528a9-fa0f-4cdb-8282-95b3b30bb883
88+ IdentityTenantId : 72f988bf-86f1-41af-91ab-2d7cd011db47
89+ IdentityType : SystemAssigned
90+ IdentityUserAssignedIdentity : {
91+ }
92+ Location : eastus
93+ Name : testfleet02
94+ ProvisioningState : Succeeded
95+ ResourceGroupName : joyer-test
96+ SystemDataCreatedAt : 4/15/2024 7:19:15 AM
97+ SystemDataCreatedBy : [email protected] 98+ SystemDataCreatedByType : User
99+ SystemDataLastModifiedAt : 4/15/2024 7:19:15 AM
100+ SystemDataLastModifiedBy : [email protected] 101+ SystemDataLastModifiedByType : User
102+ Tag : {
103+ "456": "asd"
104+ }
105+ Type : Microsoft.ContainerService/fleets
106+ ```
107+
108+ This command creates a Fleet resource with system assigned identity type.
109+
110+ ### Example 3: Creates a Fleet resource with user assigned identity type
111+ ``` powershell
112+ $mi = Get-AzUserAssignedIdentity -Name testUserAssignedMI -ResourceGroupName joyer-test
113+ New-AzFleet -Name testfleet03 -ResourceGroupName joyer-test -Location eastus -Tag @{"789"="asd"} -UserAssignedIdentity $mi.Id
114+ ```
115+
116+ ``` output
117+ ETag : "0a00e0c9-0000-0100-0000-661cd8010000"
118+ Id : /subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourceGroups/joyer-test/providers/Microsoft.ContainerService/fleets/testflee
119+ t03
120+ IdentityPrincipalId :
121+ IdentityTenantId :
122+ IdentityType : UserAssigned
123+ IdentityUserAssignedIdentity : {
124+ "/subscriptions/9e223dbe-3399-4e19-88eb-0975f02ac87f/resourcegroups/joyer-test/providers/Microsoft.ManagedIdentity/userAssignedI
125+ dentities/testUserAssignedMI": {
126+ }
127+ }
128+ Location : eastus
129+ Name : testfleet03
130+ ProvisioningState : Succeeded
131+ ResourceGroupName : joyer-test
132+ SystemDataCreatedAt : 4/15/2024 7:32:16 AM
133+ SystemDataCreatedBy : [email protected] 134+ SystemDataCreatedByType : User
135+ SystemDataLastModifiedAt : 4/15/2024 7:32:16 AM
136+ SystemDataLastModifiedBy : [email protected] 137+ SystemDataLastModifiedByType : User
138+ Tag : {
139+ "789": "asd"
140+ }
141+ Type : Microsoft.ContainerService/fleets
142+ ```
143+
77144This command creates a Fleet resource with a long running operation.
78145
79146## PARAMETERS
@@ -109,11 +176,11 @@ Accept pipeline input: False
109176Accept wildcard characters : False
110177` ` `
111178
112- ### -IdentityType
113- Type of managed service identity (where both SystemAssigned and UserAssigned types are allowed) .
179+ ### -EnableSystemAssignedIdentity
180+ Decides if enable a system assigned identity for the resource .
114181
115182` ` ` yaml
116- Type : System.String
183+ Type : System.Management.Automation.SwitchParameter
117184Parameter Sets : CreateExpanded, CreateViaIdentityExpanded
118185Aliases :
119186
@@ -291,12 +358,11 @@ Accept wildcard characters: False
291358` ` `
292359
293360### -UserAssignedIdentity
294- The set of user assigned identities associated with the resource.
295- The userAssignedIdentities dictionary keys will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}.
296- The dictionary values can be empty objects ({}) in requests.
361+ The array of user assigned identities associated with the resource.
362+ The elements in array will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}.'
297363
298364` ` ` yaml
299- Type : System.Collections.Hashtable
365+ Type : System.String[]
300366Parameter Sets : CreateExpanded, CreateViaIdentityExpanded
301367Aliases :
302368
0 commit comments