Set-AzServiceFabricManagedClusterApplicationTypeVersion
更新 Service Fabric 受控應用程式類型版本。 這可讓您更新標籤和套件 URL。 僅支援 ARM 部署的應用程式類型版本。
語法
Set-AzServiceFabricManagedClusterApplicationTypeVersion
[-ResourceGroupName] <String>
[-ClusterName] <String>
[-Name] <String>
[-Version] <String>
[-PackageUrl <String>]
[-Tag <Hashtable>]
[-Force]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-AzServiceFabricManagedClusterApplicationTypeVersion
[-PackageUrl <String>]
[-Tag <Hashtable>]
-ResourceId <String>
[-Force]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Set-AzServiceFabricManagedClusterApplicationTypeVersion
[-PackageUrl <String>]
[-Tag <Hashtable>]
-InputObject <PSManagedApplicationTypeVersion>
[-Force]
[-AsJob]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
此 Cmdlet 可用來更新應用程式類型版本標籤。
範例
範例 1
$resourceGroupName = "testRG"
$clusterName = "testCluster"
$appTypeName = "testAppType"
$version = "v1"
$newTags = @{new="tags"}
$packageUrl = "https://sftestapp.blob.core.windows.net/sftestapp/testAppType_v1.sfpkg"
Set-AzServiceFabricManagedClusterApplicationTypeVersion -ResourceGroupName $resourceGroupName -ClusterName $clusterName -Name $appTypeName -Version $version -Tag $newTags -PackageUrl $packageUrl -Verbose
此範例會更新受控應用程式類型版本 「v1」 標籤和 packageUrl。
範例 2
$resourceGroupName = "testRG"
$clusterName = "testCluster"
$appTypeName = "testAppType"
$newTags = @{new="tags"}
$packageUrl = "https://sftestapp.blob.core.windows.net/sftestapp/testAppType_v1.sfpkg"
$appType = Get-AzServiceFabricManagedClusterApplicationTypeVersion -ResourceGroupName $resourceGroupName -ClusterName $clusterName -Name $appTypeName -Version $version
$appType | Set-AzServiceFabricManagedClusterApplicationTypeVersion -Tag $newTags -PackageUrl $packageUrl -Verbose
此範例會更新受控應用程式類型版本 「v1」 標籤和 packageUrl。
範例 3
$newTags = @{new="tags"}
$packageUrl = "https://sftestapp.blob.core.windows.net/sftestapp/testAppType_v1.sfpkg"
$resourceId = "/subscriptions/13ad2c84-84fa-4798-ad71-e70c07af873f/resourcegroups/testRG/providers/Microsoft.ServiceFabric/managedClusters/testCluster/applicationTypes/testAppType/versions/v1"
Set-AzServiceFabricManagedClusterApplicationTypeVersion -ResourceId $resourceId -Tag $newTags -PackageUrl $packageUrl -Verbose
此範例會使用指定的 ARM 資源識別碼來更新受控應用程式類型詳細數據。
參數
-AsJob
在背景執行 Cmdlet,並傳回作業以追蹤進度。
類型: | SwitchParameter |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |
-ClusterName
指定叢集的名稱。
類型: | String |
Position: | 1 |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |
-Confirm
在執行 Cmdlet 之前,提示您進行確認。
類型: | SwitchParameter |
別名: | cf |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |
-DefaultProfile
用於與 Azure 通訊的認證、帳戶、租用戶和訂用帳戶。
類型: | IAzureContextContainer |
別名: | AzContext, AzureRmContext, AzureCredential |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |
-Force
在沒有提示的情況下繼續
類型: | SwitchParameter |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |
-InputObject
受控應用程式類型版本資源。
類型: | PSManagedApplicationTypeVersion |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |
-Name
指定受控應用程式類型的名稱
類型: | String |
別名: | ApplicationTypeName |
Position: | 2 |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |
-PackageUrl
指定應用程式套件 sfpkg 檔案的 URL
類型: | String |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | True |
接受萬用字元: | False |
-ResourceGroupName
指定資源群組的名稱。
類型: | String |
Position: | 0 |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |
-ResourceId
受控應用程式類型版本的 Arm ResourceId。
類型: | String |
Position: | Named |
預設值: | None |
必要: | True |
接受管線輸入: | True |
接受萬用字元: | False |
-Tag
將標記指定為索引鍵/值組。
類型: | Hashtable |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | True |
接受萬用字元: | False |
-Version
指定受控應用程式類型版本
類型: | String |
別名: | ApplicationTypeVersion |
Position: | 3 |
預設值: | None |
必要: | True |
接受管線輸入: | False |
接受萬用字元: | False |
-WhatIf
顯示 Cmdlet 執行時會發生什麼事。 指令未執行。
類型: | SwitchParameter |
別名: | wi |
Position: | Named |
預設值: | None |
必要: | False |
接受管線輸入: | False |
接受萬用字元: | False |