I'm attempting to create an Azure VM based upon the Azure VM Image for SQL 2014.
$AzureImages=Get-AzureVMImage
$AzureImages
|where{$_.Label-like'SQL Server*'}|SelectLabel,ImageName,RecommendedVMSize,PublishedDate|Format-Table-AutoSize
$AzureVMImage
=$AzureImages|where{$_.Label-eq'SQL Server 2014 RTM Standard on Windows Server 2012 R2'-and$_.PublishedDate-eq'6/9/2014 3:00:00 AM'}|SelectImageName
$AzureVMImage
This get's me the image name just fine. I'm using Azure PowerShell 0.8.10.1
However, when I try and create a VM using this image it FAILS with Invalid Image??
New-AzureVMConfig-Name$VMName-InstanceSize"Medium"-ImageName$AzureVMImage-DiskLabel"OS"-HostCachingReadOnly-AvailabilitySetName"SQLServers"|Tee-Object-VariableNewVM
Set-AzureSubnet-SubnetNames"Subnet-1"-VM$NewVM
Add-AzureProvisioningConfig-VM$NewVM-Windows-AdminUsername$UserName-Password$Password
New-AzureVM-VMs$NewVM-ServiceName$CloudService-AffinityGroup$AffinityGroup-VNetName$VNet-WaitForBoot
Instead of the above, working as it should, I get:
New-AzureVM : BadRequest: The image name is invalid.
Any ideas why?