AzureStack-QuickStart-Templ.../sharepoint-2013-non-ha-load.../azuredeploy.TestControllerR...

102 строки
4.9 KiB
JSON

{
"$schema": "https://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
"contentVersion": "1.16.8.5",
"parameters": {
"TestControllerVMName": {
"type": "string",
"metadata": {
"description": "Name of the existing test controller VM resource to use"
},
"defaultValue": "sprg-tc-0"
},
"TargetSharePointServerVMName": {
"type": "string",
"metadata": {
"description": "Machine name of the SharePoint end point to test"
},
"defaultValue": "sprg-sp-0"
},
"TargetSQLServerVMName": {
"type": "string",
"metadata": {
"description": "Machine name of the SharePoint farm's to test SQL server"
},
"defaultValue": "sprg-sql-0"
},
"NumberOfLoadTestUsers": {
"type": "int",
"metadata": {
"description": "Number of users created for load testing"
},
"defaultValue": 15
},
"LoadTestToRun": {
"type": "string",
"metadata": {
"description": "Name of the load test file to run"
},
"allowedValues": [ "CSOMListRW.loadtest", "MySiteHostRW.loadtest", "MySiteRW.loadtest" ],
"defaultValue": "MySiteHostRW.loadtest"
},
"TargetSharePointServerAdminUserName": {
"type": "string",
"metadata": {
"description": "Name of the test controller administrator account"
},
"defaultValue": "Administrator"
},
"TargetSharePointServerUserPassword": {
"type": "securestring",
"metadata": {
"description": "Password of the test controller administrator account"
}
},
"VisualStudioVersionNumber": {
"type": "int",
"metadata": {
"description": "The version number of Visual Studio installed on the test controller. For example, if Visual Studio 2013 is installed the version number is 12"
},
"defaultValue": 12
}
},
"variables": {
"assetLocation": "https://raw.githubusercontent.com/Azure/AzureStack-QuickStart-Templates/master/sharepoint-2013-non-ha-loadtest",
"LogToFileScriptName": "LogToFile.psm1",
"LogToFileScriptURL": "[concat(variables('assetLocation'),'/CommonScripts/',variables('LogToFileScriptName'))]",
"DownloadLTScriptName": "DownloadLoadTestPackage.ps1",
"DownloadLTScriptURL": "[concat(variables('assetLocation'),'/CommonScripts/',variables('DownloadLTScriptName'))]",
"PrepareLTForRunScriptName": "TestControllerPrepareLoadTest.ps1",
"PrepareLTForRunScriptURL": "[concat(variables('assetLocation'),'/TestControllerScripts/',variables('PrepareLTForRunScriptName'))]",
"StartLoadTestRunScriptName": "TestControllerStartLoadTestRun.ps1",
"StartLoadTestRunScriptURL": "[concat(variables('assetLocation'),'/TestControllerScripts/',variables('StartLoadTestRunScriptName'))]",
"RunnerScriptName": "TestControllerScriptExtensionRunner.ps1",
"RunnerScriptURL": "[concat(variables('assetLocation'),'/TestControllerScripts/',variables('RunnerScriptName'))]",
"LoadTestPackageURL": "[concat(variables('assetLocation'),'/SharePointLoadTest.zip')]",
"LoadTestUnpackLocation": "%SystemDrive%\\LoadTests\\SharePointLoadTest"
},
"resources": [
{
"type": "Microsoft.Compute/virtualMachines/extensions",
"name": "[concat(parameters('TestControllerVMName'),'/RunLoadTest')]",
"apiVersion": "2015-06-15",
"location": "[resourceGroup().location]",
"properties": {
"publisher": "Microsoft.Compute",
"type": "CustomScriptExtension",
"typeHandlerVersion": "1.8",
"autoUpgradeMinorVersion": true,
"settings": {
"fileUris": [
"[variables('LogToFileScriptURL')]",
"[variables('DownloadLTScriptURL')]",
"[variables('PrepareLTForRunScriptURL')]",
"[variables('StartLoadTestRunScriptURL')]",
"[variables('RunnerScriptURL')]"
],
"commandToExecute": "[concat('powershell -ExecutionPolicy Unrestricted -file ',variables('RunnerScriptName'),' ',variables('LoadTestPackageURL'),' ',variables('LoadTestUnpackLocation'),' ',parameters('TargetSharePointServerVMName'),' ',parameters('TargetSQLServerVMName'),' ',parameters('NumberOfLoadTestUsers'),' ',parameters('LoadTestToRun'),' ',parameters('TargetSharePointServerAdminUserName'),' ',parameters('TargetSharePointServerUserPassword'),' ',parameters('VisualStudioVersionNumber'))]"
}
}
}
],
"outputs": {}
}