I am creating VM using Ubuntu based custom image from Azure Compute Gallery. Following is the data block that I’m using to get latest image version and update the VM.
data "azurerm_shared_image_version" "stg_linux_image" {
name = "latest"
image_name = "my-ubuntu-image"
gallery_name = "my_custom_gallery"
resource_group_name = "my_pe_rg"
}
Till yesterday, it was reading the correct version. I’m using $(Build.BuildId)
to create image version names. The version names were like:
- 1.0.99549
- 1.0.99690
But yesterday the build id became six digits and the image version name is:
- 1.0.100150
After this, unless I specify 1.0.100150
, the data block is reading 1.0.99690
with latest
tag.
What am I doing wrong or is there a limitation on name length which I don’t know about?