如何部署 Azure 机器人
How to deploy an Azure Bot
我从 this tutorial. I have tested it in the Bot Framework Emulator and now want to deploy it to Azure. I am trying to follow the instructions here 的 Typescript 模板创建了一个简单的 Azure Bot。我得到了步骤“通过 ARM 模板使用现有资源组进行部署”(我已经创建了一个资源组)。
所以我正在尝试从命令行运行这个命令:
az deployment group create --resource-group "<name-of-resource-group>" --template-file "<path-to-template-with-preexisting-rg.json>" --parameters appId="<app-id-from-previous-step>" appSecret="<password-from-previous-step>" botId="<id or bot-app-service-name>" newWebAppName="<bot-app-service-name>" existingAppServicePlan="<name-of-app-service-plan>" appServicePlanLocation="<region-location-name>" --name "<bot-app-service-name>"
我收到一个错误:az deployment: 'group' is not in the 'az deployment' command group
。果然看az deployment
的帮助,没有group
命令。有一个 create
命令,但如果我删除 group
我会遇到一系列其他错误,这些错误似乎让我陷入困境。
无奈之下,我尝试安装 BotFrameworkComposer 应用程序 (Linux) 并从那里创建一个项目。它给了我一个错误 Error calling npm to fetch template. Please ensure that node and npm are installed and available on your system. Full error message: Command failed with ENOENT: npm root -g --prefix
。因此,我尝试使用“在 Composer 中打开”按钮打开我在 Azure 门户中创建的机器人资源,但没有打开任何东西。所以我将 link 从按钮复制到浏览器中(正如它所建议的那样),但应用程序没有打开。
I'm getting an error: az deployment: 'group' is not in the 'az deployment' command group. Sure enough when I look at the help for az deployment, there is no group command.
您的 AZ CLI 是什么版本?
我正在使用2.27.2
并且我有它。
C:\>az -v
azure-cli 2.27.2
core 2.27.2
telemetry 1.0.6
C:\>az deployment --help
Group
az deployment : Manage Azure Resource Manager template deployment at subscription scope.
Subgroups:
group : Manage Azure Resource Manager template deployment at resource group.
mg : Manage Azure Resource Manager template deployment at management group.
operation : Manage deployment operations at subscription scope.
sub : Manage Azure Resource Manager template deployment at subscription scope.
tenant : Manage Azure Resource Manager template deployment at tenant scope.
C:\>az deployment group --help
Group
az deployment group : Manage Azure Resource Manager template deployment at resource group.
Commands:
cancel : Cancel a deployment at resource group.
create : Start a deployment at resource group.
delete : Delete a deployment at resource group.
export : Export the template used for a deployment.
list : List deployments at resource group.
show : Show a deployment at resource group.
validate : Validate whether a template is valid at resource group.
wait : Place the CLI in a waiting state until a deployment condition is met.
what-if : Execute a deployment What-If operation at resource group scope.
我从 this tutorial. I have tested it in the Bot Framework Emulator and now want to deploy it to Azure. I am trying to follow the instructions here 的 Typescript 模板创建了一个简单的 Azure Bot。我得到了步骤“通过 ARM 模板使用现有资源组进行部署”(我已经创建了一个资源组)。
所以我正在尝试从命令行运行这个命令:
az deployment group create --resource-group "<name-of-resource-group>" --template-file "<path-to-template-with-preexisting-rg.json>" --parameters appId="<app-id-from-previous-step>" appSecret="<password-from-previous-step>" botId="<id or bot-app-service-name>" newWebAppName="<bot-app-service-name>" existingAppServicePlan="<name-of-app-service-plan>" appServicePlanLocation="<region-location-name>" --name "<bot-app-service-name>"
我收到一个错误:az deployment: 'group' is not in the 'az deployment' command group
。果然看az deployment
的帮助,没有group
命令。有一个 create
命令,但如果我删除 group
我会遇到一系列其他错误,这些错误似乎让我陷入困境。
无奈之下,我尝试安装 BotFrameworkComposer 应用程序 (Linux) 并从那里创建一个项目。它给了我一个错误 Error calling npm to fetch template. Please ensure that node and npm are installed and available on your system. Full error message: Command failed with ENOENT: npm root -g --prefix
。因此,我尝试使用“在 Composer 中打开”按钮打开我在 Azure 门户中创建的机器人资源,但没有打开任何东西。所以我将 link 从按钮复制到浏览器中(正如它所建议的那样),但应用程序没有打开。
I'm getting an error: az deployment: 'group' is not in the 'az deployment' command group. Sure enough when I look at the help for az deployment, there is no group command.
您的 AZ CLI 是什么版本?
我正在使用2.27.2
并且我有它。
C:\>az -v
azure-cli 2.27.2
core 2.27.2
telemetry 1.0.6
C:\>az deployment --help
Group
az deployment : Manage Azure Resource Manager template deployment at subscription scope.
Subgroups:
group : Manage Azure Resource Manager template deployment at resource group.
mg : Manage Azure Resource Manager template deployment at management group.
operation : Manage deployment operations at subscription scope.
sub : Manage Azure Resource Manager template deployment at subscription scope.
tenant : Manage Azure Resource Manager template deployment at tenant scope.
C:\>az deployment group --help
Group
az deployment group : Manage Azure Resource Manager template deployment at resource group.
Commands:
cancel : Cancel a deployment at resource group.
create : Start a deployment at resource group.
delete : Delete a deployment at resource group.
export : Export the template used for a deployment.
list : List deployments at resource group.
show : Show a deployment at resource group.
validate : Validate whether a template is valid at resource group.
wait : Place the CLI in a waiting state until a deployment condition is met.
what-if : Execute a deployment What-If operation at resource group scope.