Skip to content

Is the VHD a Generalized Image? #5357

Discussion options

You must be logged in to vote

generalization steps manually? - Yep, that's right, Linux\Windows are already generalized and no need any additional steps.

E.g. function how we upload images to a gallery:

function New-ImageFromVHD
{
    # Create an image from a VHD
    $osVhdUri = "https://${imageStorageAccount}.blob.core.windows.net/vhds/${imageBlobName}"
    Write-Host "Creating an image with '${imageName}' name from '${osVhdUri}' VHD that uses '${imageStorageAccount}' storage account..."
    $imageConfig = New-AzImageConfig -Location $location
    $imageConfig = Set-AzImageOsDisk -Image $imageConfig -OsType $imageOperatingSystem -OsState Generalized -BlobUri $osVhdUri
    New-AzImage -ImageName $imageName -ResourceGr…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@Malaw80s
Comment options

@Malaw80s
Comment options

Answer selected by Malaw80s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants