1
votes

I an using this github repo in order to join an Virtual Machine to an existing Azure Active Directory Domain :

https://github.com/Azure/azure-quickstart-templates/tree/master/201-vm-domain-join-existing

My attempt is to use it in a fully automated way with azure CLI

I have used this bash command line so far:

az group deployment create --resource-group sql-rg --name slq-vm --template-uri https://raw.githubusercontent.com/Azure/azure-quickstart-templates/master/201-vm-domain-join-existing/azuredeploy.json --parameters '{ "vmList": "sql-vm", "location":"uksouth", "domainJoinUserName":"[email protected]", "domainJoinUserPassword":"*****", "domainFQDN":"myfqdn" }'

After executing this command I do get this error:

Azure Error: InvalidRequestContent Message: The request content was invalid and could not be deserialized: 'Error converting value "sql-vm" to type 'Microsoft.WindowsAzure.ResourceStack.Frontdoor.Data.Definitions.DeploymentParameterDefinition'. Path 'properties.parameters.vmList', line 1, position 196.'.

What is the right way to set parameters?

1

1 Answers

1
votes

Just for saving time for others:

--parameters '{ "vmList": {"value":"sql-vm"}, "domainJoinUserName": {"value":"[email protected]"}, "domainJoinUserPassword":{"value":"*****"}, "domainFQDN":{"value":"myfqdn"} }'

the parameter should be specified in the proper way.