0
我已經編寫了一個task.json文件,下面是代碼,並試圖創建一個插件..這是我的插件輸入。我能夠看到天藍色的subcriptions但資源組名稱不是自動填充的。我應該添加什麼?無法獲取列表中的資源組名稱
`"inputs":[
{
"name": "ConnectedServiceNameSelector",
"type": "pickList",
"label": "Cloud Provider",
"required": false,
"helpMarkDown": "",
"defaultValue": "",
"options": {
"ConnectedServiceNameARM": "Azure RM",
"ConnectedServiceNameAWS": "AWS"
}
},
{
"name": "ConnectedServiceNameARM",
"type": "connectedService:AzureRM",
"label": "Azure RM Subscription",
"defaultValue": "",
"required": true,
"helpMarkDown": "Azure Resource Manager subscription to target for copying the files.",
"visibleRule": "ConnectedServiceNameSelector = ConnectedServiceNameARM"
},
{
"name": "ConnectedServiceNameAWS",
"type": "connectedService:AWS",
"label": "AWS",
"defaultValue": "",
"required": true,
"helpMarkDown": "AWS subscription to target for copying the files.",
"visibleRule": "ConnectedServiceNameSelector = ConnectedServiceNameAWS"
},
{
"name": "ResourceGroupName",
"label": "Resource Group",
"type": "pickList",
"required": true,
"groupName": "AzureDetails",
"helpMarkDown": "Provide the name of a resource group.",
"properties": {
"EditableOptions": "True"
}
},
{
"name": "action",
"type": "pickList",
"label": "Operation",
"defaultValue": "Create Or Update Resource Group",
"required": true,
"groupName": "AzureDetails",
"helpMarkDown": "Action to be performed on the Azure resources or resource group.",
"options": {
"Create Or Update Resource Group": "Create or update resource group",
"Select Resource Group": "Select resource group",
"Start": "Start virtual machines",
"Stop": "Stop virtual machines",
"Restart": "Restart virtual machines",
"Delete": "Delete virtual machines",
"DeleteRG": "Delete resource group"
}
},
{
"name": "deploymentName",
"type": "string",
"label": "Deployment Name",
"required": false,
"defaultValue": "",
"groupName": "AzureDetails",
"helpMarkDown": "Provide a deployment name"
},
{
"name": "location",
"type": "pickList",
"label": "Region",
"defaultValue": "Southeast Asia",
"required": true,
"helpMarkDown": "Location for deploying the resource group. If the resource group already exists in the subscription, then this value will be ignored.",
"groupName": "AzureDetails",
"options": {
"Australia East": "Australia East",
"Australia Southeast": "Australia Southeast",
"Brazil South": "Brazil South",
"Canada Central": "Canada Central",
"Canada East": "Canada East",
"Central India": "Central India",
"Central US": "Central US",
"East Asia": "East Asia",
"East US": "East US",
"East US 2 ": "East US 2 ",
"Japan East": "Japan East",
"Japan West": "Japan West",
"North Central US": "North Central US",
"North Europe": "North Europe",
"South Central US": "South Central US",
"South India": "South India",
"Southeast Asia": "Southeast Asia",
"UK South": "UK South",
"UK West": "UK West",
"West Central US": "West Central US",
"West Europe": "West Europe",
"West India": "West India",
"West US": "West US",
"West US 2": "West US 2"
},
"properties": {
"EditableOptions": "True"
},
"visibleRule": "action = Create Or Update Resource Group || action = Select Resource Group || action = DeleteRG"
},
}
],
"dataSourceBindings": [
{
"target": "ResourceGroupName",
"endpointId": "$(ConnectedServiceName)",
"dataSourceName": "AzureResourceGroups"
},
{
"target": "location",
"endpointId": "$(ConnectedServiceName)",
"dataSourceName": "AzureLocations"
},
],
`