az stack-hci-vm image
Note
This reference is part of the stack-hci-vm extension for the Azure CLI (version 2.15.0 or higher). The extension will automatically install the first time you run an az stack-hci-vm image command. Learn more about extensions.
Manage images with stack-hci-vm.
Commands
Name | Description | Type | Status |
---|---|---|---|
az stack-hci-vm image create |
Create a gallery image. |
Extension | GA |
az stack-hci-vm image delete |
Delete an image. |
Extension | GA |
az stack-hci-vm image list |
List all gallery images. |
Extension | GA |
az stack-hci-vm image show |
Get the details of an image. |
Extension | GA |
az stack-hci-vm image update |
Update an image. |
Extension | GA |
az stack-hci-vm image create
Create a gallery image.
az stack-hci-vm image create --custom-location
--name
--os-type
--resource-group
[--image-path]
[--imagerepo-password]
[--imagerepo-username]
[--location]
[--offer]
[--polling-interval]
[--publisher]
[--sku]
[--source-vm]
[--storage-path-id]
[--tags]
[--urn]
[--version]
Examples
PutGalleryImage
az stack-hci-vm image create --custom-location "/subscriptions/a95612cb-f1fa-4daa-a4fd-272844fa512c/resourceGroups/dogfoodarc/providers/Microsoft.ExtendedLocation/customLocations/dogfood-location" --location "West US2" --storage-path-id "/subscriptions/a95612cb-f1fa-4daa-a4fd-272844fa512c/resourceGroups/dogfoodarc/providers/Microsoft.AzureStackHCI/storagecontainers/test-storagepath" --image-path "C:\\test.vhdx" --name "test-gallery-image" --resource-group "test-rg" --os-type "Windows"
Required Parameters
The ID of the extended location.
Name of the gallery image.
OS Type [Windows, Linux].
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Location/Path of the image the gallery image should be created from.
Password for accessing acr image repository.
Username for accessing acr image repository.
If location is not specified, the location of the resource group is used.
Offer for Marketplace image.
Usage: --offer.
ARM polling interval for long running operations.
Publisher for Marketplace image.
Usage: --publisher.
Sku for Marketplace image.
Usage: --sku.
Name of the source vm whose os disk the gallery image should be created from.
Azure ID of the Storage Path which is used to store the Gallery Images.
Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.
URN, in format of 'publisher:offer:sku:version'. If specified, other argument values can be omitted.
Version for Marketplace image.(This will be ignored if --urn is passed).
Usage: --version.
Property | Value |
---|---|
Default value: | latest |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az stack-hci-vm image delete
Delete an image.
az stack-hci-vm image delete [--ids]
[--name]
[--polling-interval]
[--resource-group]
[--subscription]
[--yes]
Examples
DeleteGalleryImage
az stack-hci-vm image delete --name "test-gallery-image" --resource-group "test-rg"
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name of the gallery image.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
ARM polling interval for long running operations.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Do not prompt for confirmation.
Property | Value |
---|---|
Default value: | False |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az stack-hci-vm image list
List all gallery images.
az stack-hci-vm image list [--resource-group]
Examples
ListGalleryImageByResourceGroup
az stack-hci-vm image list --resource-group "test-rg"
ListGalleryImageBySubscription
az stack-hci-vm image list
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az stack-hci-vm image show
Get the details of an image.
az stack-hci-vm image show [--ids]
[--name]
[--resource-group]
[--subscription]
Examples
GetGalleryImage
az stack-hci-vm image show --name "test-gallery-image" --resource-group "test-rg"
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name of the gallery image.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |
az stack-hci-vm image update
Update an image.
az stack-hci-vm image update [--ids]
[--name]
[--polling-interval]
[--resource-group]
[--subscription]
[--tags]
Examples
UpdateGalleryImage
az stack-hci-vm image update --tags additionalProperties="sample" --name "test-gallery-image" --resource-group "test-rg"
Optional Parameters
The following parameters are optional, but depending on the context, one or more might become required for the command to execute successfully.
One or more resource IDs (space-delimited). It should be a complete resource ID containing all information of 'Resource Id' arguments. You should provide either --ids or other 'Resource Id' arguments.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name of the gallery image.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
ARM polling interval for long running operations.
Name of resource group. You can configure the default group using az configure --defaults group=<name>
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Name or ID of subscription. You can configure the default subscription using az account set -s NAME_OR_ID
.
Property | Value |
---|---|
Parameter group: | Resource Id Arguments |
Space-separated tags: key[=value] [key[=value] ...]. Use "" to clear existing tags.
Global Parameters
Increase logging verbosity to show all debug logs.
Property | Value |
---|---|
Default value: | False |
Show this help message and exit.
Only show errors, suppressing warnings.
Property | Value |
---|---|
Default value: | False |
Output format.
Property | Value |
---|---|
Default value: | json |
Accepted values: | json, jsonc, none, table, tsv, yaml, yamlc |
JMESPath query string. See http://jmespath.org/ for more information and examples.
Increase logging verbosity. Use --debug for full debug logs.
Property | Value |
---|---|
Default value: | False |