2017-02-14 9 views
0

以下のtask.jsonファイルをコードとして作成しました。プラグインを作成しようとしています。これはプラグインの入力です。私は紺碧のサブクラスを見ることができますリソースグループ名はautopopulatingではありません。私は何を追加すべきですか?リスト内のリソースグループ名を取得できません

`"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" 
    }, 

], 

`

これはあなたのエンドポイントの入力は

"name": "ConnectedServiceNameARM" 

であるが、データバインディングにおけるエンドポイント名は末尾にARMなしでenter image description here

答えて

0

VSTS の私のプラグインのUIである

"endpointId": "$(ConnectedServiceName)" 

・ホープこのヘルプあなたは資源が選択したグループのみ

{ 
     "target": "AutomationAccount", 
     "endpointId": "$(ConnectedServiceName)", 
     "dataSourceName": "AutomationAccountNames", 
     "parameters": { 
      "ResourceGroupName": "$(ResourceGroupName)" 
     } 
    } 
をint型にも使用したい

関連する問題