azure-vm-agents-plugin
azure-vm-agents-plugin copied to clipboard
Unable to validate template when specifying existing storage account with custom image URI
I am using a groovy file to populate the settings field of the plugin.
I am getting an error that states "The storage account name already exists. Use a different name." when I attempt to prepopulate with a Custom Image URI.
If I specify a different storage account, I get "The reference image should be in the same storage account as the one declared in the template."
Azure requires that a VHD for a custom image be in the same resource group as a VM getting created from one, if the plugin validation requires the resource group to have previously existed however, then we get a bit of a "chicken-and-egg" scenario.
Attached is a version of the groovy file I am using to populate the plugin fields (minus sensitive data of course).
I am using a jar compiled from commit 26cd3fabaad549e5ac70b583f1e448a8c273a546 (May 9th)
[JENKINS-44566] created by scarvel8
Took a look through the code,
Storage account is in the same resource group, still showing same errors
by scarvel8
I finally got passed the validation ![]()
- In Azure Profile Configuration make sure you use the same resource group as where the image resides.
- Storage Account Name can be the same as where you created your vhd image from
https://xxxxxxxxxxxxxxx.blob.core.windows.net/vhds/xxxxxxx20170603121101.vhd
If you need more info, let me know.
by joeystevense
I am able to work around the issue by working around the validation, for now that works for me so I will close this issue
by scarvel8
Joey Stevense I'm getting the "The reference image should be in the same storage account as the one declared in the template." while image pointed by "Custom Image URI" belongs to a storage account within selected Resource Group Name.
There are no records under the Use existing list.
What would you suggest?
by kentzo
I see "The reference image should be in the same storage account as the one declared in the template." while image pointed by "Custom Image URI" belongs to a storage account within selected Resource Group Name.
I am getting no records under the 'Use Exist List' too.
Are there any fixes/work-arounds for this?
by captainwhippet
Hi, we are suddenly getting the following error: "The storage account name already exists. Use a different name."
We haven't change the storage account we use and the custom URL image is located in that storage account.
Any ideas on what could be the problem?
by roni