小编Neg*_*tar的帖子

关于 cmdlet 'Get-AzKeyVaultSecret' SecretValueText 中的重大更改的警告已弃用 Az4.6.1

我今天将 Az Powershell 升级到 4.6.1 并开始看到以下警告。我的问题是我应该如何处理这个警告?我可以将警告静音,但这根本无法帮助我为这一重大变化做好准备。我检查了 Az 4.6.1 Microsoft 文档,他们告诉我我应该仍然使用 SecretValueText 并且没有提供关于弃用或任何其他获取秘密值的替代方法的类似警告。那么我使用 SecretValueText 读取 KeyVault 机密的 powershell 的更新路径是什么?

WARNING: Breaking changes in the cmdlet 'Get-AzKeyVaultSecret' :
WARNING:  - "The output type 'Microsoft.Azure.Commands.KeyVault.Models.PSKeyVaultSecret' is changing" 
- The following properties in the output type are being deprecated :
 'SecretValueText'
WARNING: Note :The change is expected to take effect from the version :  '3.0.0'
WARNING:  - "The output type 'Microsoft.Azure.Commands.KeyVault.Models.PSDeletedKeyVaultSecret' is changing"
 - The following properties in the output type are being …
Run Code Online (Sandbox Code Playgroud)

azure azure-powershell

14
推荐指数
4
解决办法
6854
查看次数

使用ARM将Azure RBAC应用于资源

有没有办法通过ARM在资源级别应用RBAC规则?我能够按照此Microsoft指南在资源组级别而不是资源上添加用户/角色。特别是,我试图通过ARM向AppInsights添加新的读者角色。但是,当我调整范围时,模板只会因以下错误而失败:

"error": {
"code": "InvalidCreateRoleAssignmentRequest",
"message": "The request to create role assignment '{guid}' is not valid. Role assignment scope '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/Microsoft.Insights/components/{resourceGroupName}' must match the scope specified on the URI  '/subscriptions/{resourceGroupName}/resourcegroups/{resourceGroupName}'."
  }
Run Code Online (Sandbox Code Playgroud)

我不知道范围变量是什么,如果不能更改。我应该在其他地方修改范围以使此工作正常吗?

提前致谢!

json rbac azure azure-rm-template

7
推荐指数
2
解决办法
868
查看次数

标签 统计

azure ×2

azure-powershell ×1

azure-rm-template ×1

json ×1

rbac ×1