如何将证书添加到 azure service fabric 集群 vmset
How to add a Certificate to an azure service fabric cluster vmset
我有一个 Service Fabric 集群,它有一个基于密钥保管库的 vmset 来存储其机密。它运行良好,但现在我需要向 运行 实例上的个人商店添加证书(优先选择,无需在 RDP 中手动执行)。我使用 powershell 将证书添加到密钥库中,但即使在增加 vmset 的容量后,新虚拟机也没有新证书。
当我尝试 "reimage" 现有虚拟机时,出现错误
Failed to reimage virtual machine instance 'xxxxxxx'. Error: Virtual
Machine Scale Sets with extension
Microsoft.Azure.ServiceFabric.ServiceFabricNode cannot be reimaged.
所以我虽然可以使用以下命令更新虚拟机上的证书
$vm = Add-AzureVMSecret -VM $vm -SourceVaultId $SourceVaultId -CertificateStore $certStore -CertificateUrl $certUrl;
Update-AzureRmVM -ResourceGroupName $resourceGroup -VM $vm
但我似乎无法在 vmset 中获取单个 vm。
$vm = Get-AzureRmVM -ResourceGroupName $resourceGroupName -Name "xxxxxx"
Get-AzureRmVM : The Resource
'Microsoft.Compute/virtualMachines/xxxxxx' under resource group
'xxxxxxxxxxxxxxx' was not found. StatusCode: 404 ReasonPhrase: Not
Found
有谁知道如何在 vmset 中的现有 vm 上添加证书?
如果我需要更新即将过期的证书怎么办,似乎我需要做一些类似的事情。
我有一个 Service Fabric 集群,它有一个基于密钥保管库的 vmset 来存储其机密。它运行良好,但现在我需要向 运行 实例上的个人商店添加证书(优先选择,无需在 RDP 中手动执行)。我使用 powershell 将证书添加到密钥库中,但即使在增加 vmset 的容量后,新虚拟机也没有新证书。
当我尝试 "reimage" 现有虚拟机时,出现错误
Failed to reimage virtual machine instance 'xxxxxxx'. Error: Virtual Machine Scale Sets with extension Microsoft.Azure.ServiceFabric.ServiceFabricNode cannot be reimaged.
所以我虽然可以使用以下命令更新虚拟机上的证书
$vm = Add-AzureVMSecret -VM $vm -SourceVaultId $SourceVaultId -CertificateStore $certStore -CertificateUrl $certUrl;
Update-AzureRmVM -ResourceGroupName $resourceGroup -VM $vm
但我似乎无法在 vmset 中获取单个 vm。
$vm = Get-AzureRmVM -ResourceGroupName $resourceGroupName -Name "xxxxxx"
Get-AzureRmVM : The Resource 'Microsoft.Compute/virtualMachines/xxxxxx' under resource group 'xxxxxxxxxxxxxxx' was not found. StatusCode: 404 ReasonPhrase: Not Found
有谁知道如何在 vmset 中的现有 vm 上添加证书? 如果我需要更新即将过期的证书怎么办,似乎我需要做一些类似的事情。