-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Updated IoT Central .NET package to 4.0.0 (RP version 2021-06-01) with support for Managed Identities #16438
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 2 commits
d6748e4
3bc6a3b
8cd4506
1bf248f
7d6b85c
63de737
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -19,6 +19,10 @@ | |
| --> | ||
| ## Upcoming Release | ||
|
|
||
| ## Version 1.0.0 | ||
| * Stable release version, updated to IoT Central .NET Management Plane SDK version 4.0.0. | ||
| * This change introduces support for System-Assigned Managed Identities, adds support for regional locations like 'eastus' (while removing support for geographic locations like 'unitedstates'), and removes support for legacy S1 sku. | ||
|
||
|
|
||
| ## Version 0.9.0 | ||
| * Update our Azure PowerShell command to use our latest released .NET package with the version of 3.1.0. | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -54,6 +54,11 @@ public class SetAzureRmIotCentralApp : IotCentralFullParameterSetCmdlet | |
| [ValidateNotNullOrEmpty] | ||
| public string Sku { get; set; } | ||
|
|
||
| [Parameter( | ||
| Mandatory = false, | ||
| HelpMessage = "Managed Identity Type. Can be None or SystemAssigned.")] | ||
| public string Identity { get; set; } | ||
|
|
||
| public override void ExecuteCmdlet() | ||
| { | ||
| this.SetNameAndResourceGroup(); | ||
|
|
@@ -67,7 +72,23 @@ public override void ExecuteCmdlet() | |
|
|
||
| private AppPatch CreateApplicationPatch() | ||
| { | ||
| return new AppPatch(TagsConversionHelper.CreateTagDictionary(this.Tag, true), new AppSkuInfo(this.Sku), null, this.DisplayName, this.Subdomain); | ||
| var appPatch = new AppPatch( | ||
| tags: TagsConversionHelper.CreateTagDictionary(this.Tag, true), | ||
| sku: new AppSkuInfo(this.Sku), | ||
| displayName: this.DisplayName, | ||
| subdomain: this.Subdomain | ||
| ); | ||
|
|
||
| if (!string.IsNullOrEmpty(this.Identity)) | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Say I have an existing application with a System Assigned Identity, if I run the PATCH command and don't specify anything for Identity, won't this get rid of my identity by going to the
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. probably just check if this.Identity has value
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, I've removed the else and added validation on tests. |
||
| { | ||
| appPatch.Identity = new SystemAssignedServiceIdentity(type: this.Identity); | ||
| } | ||
| else | ||
| { | ||
| appPatch.Identity = new SystemAssignedServiceIdentity(type: SystemAssignedServiceIdentityType.None); | ||
| } | ||
|
|
||
| return appPatch; | ||
| } | ||
| } | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -56,6 +56,7 @@ Subdomain : MyAppSubdomain | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| ### Example 2 Get IoT Central Applications in Subscription. | ||
| ```powershell | ||
|
|
@@ -79,6 +80,7 @@ Subdomain : MyAppSubdomain | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| ResourceId : /subscriptions/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/resourceGroups/MyResourceGroupName2/providers/Microsoft | ||
| .IoTCentral/IoTApps/MyAppResourceName2 | ||
|
|
@@ -93,6 +95,7 @@ Subdomain : MyAppSubdomain2 | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName2 | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| ### Example 3 Get IoT Central Applications in Resource Group. | ||
| ```powershell | ||
|
|
@@ -116,6 +119,7 @@ Subdomain : MyAppSubdomain | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| ResourceId : /subscriptions/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/resourceGroups/MyResourceGroupName/providers/Microsoft | ||
| .IoTCentral/IoTApps/MyAppResourceName2 | ||
|
|
@@ -130,6 +134,7 @@ Subdomain : MyAppSubdomain2 | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| ## PARAMETERS | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -13,7 +13,7 @@ Creates a new IoT Central Application. | |
| ## SYNTAX | ||
|
|
||
| ``` | ||
| New-AzIotCentralApp [-Subdomain] <String> [-DisplayName <String>] [-Template <String>] [-Sku <String>] | ||
| New-AzIotCentralApp [-Subdomain] <String> [-DisplayName <String>] [-Template <String>] [-Sku <String>] [-Identity <String>] | ||
| [-Location <String>] [-Tag <Hashtable>] [-AsJob] [-ResourceGroupName] <String> [-Name] <String> | ||
| [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>] | ||
| ``` | ||
|
|
@@ -43,6 +43,7 @@ Subdomain : MyAppSubdomain | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| Create an IoT Central application in the standard pricing tier ST2, in the region of the resource group. | ||
|
|
||
|
|
@@ -66,6 +67,7 @@ Subdomain : MyAppSubdomain | |
| Template : [email protected] | ||
| SubscriptionId : XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX | ||
| ResourceGroupName : MyResourceGroupName | ||
| Identity : Microsoft.Azure.Management.IotCentral.Models.SystemAssignedServiceIdentity | ||
|
|
||
| Create an IoT Central application with the standard pricing tier ST2 in the 'westus' region, with a custom display name, based on the iotc-default template. | ||
|
|
||
|
|
@@ -226,6 +228,22 @@ Accept pipeline input: True (ByPropertyName) | |
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### -Identity | ||
| The type of managed identity for the IoT Central application. | ||
| Default value is None. System-assigned managed identities are supported. | ||
|
|
||
| ```yaml | ||
| Type: System.String | ||
| Parameter Sets: (All) | ||
| Aliases: | ||
|
|
||
| Required: False | ||
| Position: Named | ||
| Default value: None | ||
| Accept pipeline input: False | ||
| Accept wildcard characters: False | ||
| ``` | ||
|
|
||
| ### -Confirm | ||
| Prompts you for confirmation before running the cmdlet. | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.