Skip to content

Commit 7801ff6

Browse files
authored
Update New-AzGalleryImageVersion.md (#26259)
Wrong property was used to create from a VM
1 parent 1d38525 commit 7801ff6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Compute/Compute/help/New-AzGalleryImageVersion.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ $galleryName = "myGallery"
3838
$galleryImageDefinitionName = "myImage"
3939
$galleryImageVersionName = "1.0.0"
4040
$location = "eastus"
41-
$sourceImageId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myVMRG/providers/Microsoft.Compute/virtualMachines/myVM"
42-
New-AzGalleryImageVersion -ResourceGroupName $rgName -GalleryName $galleryName -GalleryImageDefinitionName $galleryImageDefinitionName -Name $galleryImageVersionName -Location $location -SourceImageId $sourceImageId
41+
$sourceImageVMId = "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myVMRG/providers/Microsoft.Compute/virtualMachines/myVM"
42+
New-AzGalleryImageVersion -ResourceGroupName $rgName -GalleryName $galleryName -GalleryImageDefinitionName $galleryImageDefinitionName -Name $galleryImageVersionName -Location $location -SourceImageVMId $sourceImageVMId
4343
```
4444

4545
Add a new image version from a virtual machine into the image definition.

0 commit comments

Comments
 (0)