azure - 如何获取用于资源组部署的最新 Azure 库模板?

标签 azure azure-powershell azure-resource-manager

我使用 Get-AzureResourceGroupGalleryTemplate Azure PowerShell cmdlet 获取用于资源组部署的 Azure 资源组库模板,但在我将 PowerShell 升级到最新版本 (1.0 .1)。

有什么替代方法可以做到这一点?

最佳答案

最新的 Azure PowerShell 修订版 (1.0.1) 中已弃用 Get-AzureResourceGroupGalleryTemplate cmdlet。

有几种选择。

  1. 使用Azure 快速入门模板

    您可以前往Azure Quickstart Templates .

    此链接包含用于快速启动部署的最新 Azure 库模板列表,这些模板始终是最新的。

  2. 对 Microsoft Azure Gallery 端点的 GET 请求 REST API 调用

    向 Microsoft Azure Gallery 端点发出 GET 请求:https://gallery.azure.com/Microsoft.Gallery/GalleryItems?api-version=2015-10-01

    预期响应应采用 JSON 格式,包含 Azure 库模板项目列表。

    下面显示了从 JSON 响应返回的图库模板之一。

"identity": "Microsoft.Windows10Enterprisex64.1.0.0",
"publisher": "Microsoft",
"publisherDisplayName": "Microsoft",
"itemName": "Windows10Enterprisex64",
"itemDisplayName": "Windows 10 Enterprise (x64)",...

希望这有帮助!

关于azure - 如何获取用于资源组部署的最新 Azure 库模板?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34066767/

相关文章:

Azure Cosmos DB 存储过程 |选择并返回没有分区 ID 值的多个文档

azure - 递归列出 Azure 资源组中的所有资源标签

powershell - 用于获取虚拟机端口的Azure powershell命令

powershell - Azure 发布管道 Powershell 任务失败

azure - Bicep 将存储帐户连接字符串传递到 key 保管库 secret

azure - 虚拟机中的 IoT Edge 离线功能

python - 如何解释 vowpal wabbit --rank 模型的 --audit 和 --invert_hash 输出?

azure - 为什么这个零结果 Cosmos DB 查询如此昂贵?

Azure 事件网格出站限制

azure - 如何在azure ARM模板中编写内联azure函数