Azure setup Error : InvalidTemplateDeployment

When I try to follow the instructions on
I get an error, everything seems to be identical to the example until I run the final step.

I seem to have run into the same problem in following instructions to deploy linux servers on azure. Does anyone have a solution to this or should I just give up on azure? I am not a azure guru and would appreciate any help with this.

I got the same error, it’s likely because the subscription you chose has it’s server physically located somewhere different than where the VM is trying to spin up.

Here is the code that you are running to create the VM:

If you paste that into notepad then you can change line 11 to the location of your subscription server.
For example my Pay-As-You-Go subscription is located in East US, so I replaced
az group create --name $vmname -l westus2
az group create --name $vmname -l eastus

Then I pasted all that into bash cloud shell and it worked.

How did you resolve this issue? I’m have the same problem but cannot find a solution from the replies you have.