Skip to content

Commit 5ee1bc5

Browse files
Merge pull request #233027 from msLinuxNinja/cli-ps-findimage
[Doc-a-thon]
2 parents e06c5b0 + 0fec7e4 commit 5ee1bc5

File tree

1 file changed

+14
-20
lines changed

1 file changed

+14
-20
lines changed

articles/virtual-machines/linux/cli-ps-findimage.md

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ You can also browse available images and offers using the [Azure Marketplace](ht
2222

2323
A Marketplace image in Azure has the following attributes:
2424

25-
* **Publisher**: The organization that created the image. Examples: Canonical, MicrosoftWindowsServer
26-
* **Offer**: The name of a group of related images created by a publisher. Examples: UbuntuServer, WindowsServer
27-
* **SKU**: An instance of an offer, such as a major release of a distribution. Examples: 18.04-LTS, 2019-Datacenter
25+
* **Publisher**: The organization that created the image. Examples: Canonical, RedHat, SUSE
26+
* **Offer**: The name of a group of related images created by a publisher. Examples: UbuntuServer, RHEL, sles-12-sp5
27+
* **SKU**: An instance of an offer, such as a major release of a distribution. Examples: 18.04-LTS, 7_9, gen2
2828
* **Version**: The version number of an image SKU.
2929

3030
These values can be passed individually or as an image *URN*, combining the values separated by the colon (:). For example: *Publisher*:*Offer*:*Sku*:*Version*. You can replace the version number in the URN with `latest` to use the latest version of the image.
@@ -53,13 +53,7 @@ x64 opensuse-leap-15-3 SUSE gen2
5353
x64 RHEL RedHat 7-LVM RedHat:RHEL:7-LVM:latest RHEL latest
5454
x64 sles-15-sp3 SUSE gen2 SUSE:sles-15-sp3:gen2:latest SLES latest
5555
x64 UbuntuServer Canonical 18.04-LTS Canonical:UbuntuServer:18.04-LTS:latest UbuntuLTS latest
56-
x64 WindowsServer MicrosoftWindowsServer 2022-Datacenter MicrosoftWindowsServer:WindowsServer:2022-Datacenter:latest Win2022Datacenter latest
57-
x64 WindowsServer MicrosoftWindowsServer 2022-datacenter-azure-edition-core MicrosoftWindowsServer:WindowsServer:2022-datacenter-azure-edition-core:latest Win2022AzureEditionCore latest
58-
x64 WindowsServer MicrosoftWindowsServer 2019-Datacenter MicrosoftWindowsServer:WindowsServer:2019-Datacenter:latest Win2019Datacenter latest
59-
x64 WindowsServer MicrosoftWindowsServer 2016-Datacenter MicrosoftWindowsServer:WindowsServer:2016-Datacenter:latest Win2016Datacenter latest
60-
x64 WindowsServer MicrosoftWindowsServer 2012-R2-Datacenter MicrosoftWindowsServer:WindowsServer:2012-R2-Datacenter:latest Win2012R2Datacenter latest
61-
x64 WindowsServer MicrosoftWindowsServer 2012-Datacenter MicrosoftWindowsServer:WindowsServer:2012-Datacenter:latest Win2012Datacenter latest
62-
x64 WindowsServer MicrosoftWindowsServer 2008-R2-SP1 MicrosoftWindowsServer:WindowsServer:2008-R2-SP1:latest Win2008R2SP1 latest
56+
[...]
6357
```
6458

6559
## Find specific images
@@ -68,7 +62,7 @@ You can filter the list of images by `--publisher` or another parameter to limit
6862

6963
For example, the following command displays all Debian offers:
7064

71-
```azurecli
65+
```azurecli-interactive
7266
az vm image list --offer Debian --all --output table
7367
```
7468

@@ -79,18 +73,18 @@ Another way to find an image in a location is to run the [az vm image list-publi
7973

8074
1. List the image publishers for a location. In this example, we're looking at the *West US* region.
8175

82-
```azurecli
76+
```azurecli-interactive
8377
az vm image list-publishers --location westus --output table
8478
```
8579
8680
1. For a given publisher, list their offers. In this example, we add *RedHat* as the publisher.
8781
88-
```azurecli
82+
```azurecli-interactive
8983
az vm image list-offers --location westus --publisher RedHat --output table
9084
```
9185
9286
1. For a given offer, list their SKUs. In this example, we add *RHEL* as the offer.
93-
```azurecli
87+
```azurecli-interactive
9488
az vm image list-skus --location westus --publisher RedHat --offer RHEL --output table
9589
```
9690
@@ -100,7 +94,7 @@ Another way to find an image in a location is to run the [az vm image list-publi
10094
10195
1. For a given publisher, offer, and SKU, show all of the versions of the image. In this example, we add *9_1* as the SKU.
10296
103-
```azurecli
97+
```azurecli-interactive
10498
az vm image list \
10599
--location westus \
106100
--publisher RedHat \
@@ -124,7 +118,7 @@ To view an image's purchase plan information, run the [az vm image show](/cli/az
124118
125119
For example, the Canonical Ubuntu Server 18.04 LTS image doesn't have extra terms, because the `plan` information is `null`:
126120
127-
```azurecli
121+
```azurecli-interactive
128122
az vm image show --location westus --urn Canonical:UbuntuServer:18.04-LTS:latest
129123
```
130124

@@ -146,7 +140,7 @@ Output:
146140

147141
Running a similar command for the RabbitMQ Certified by Bitnami image shows the following `plan` properties: `name`, `product`, and `publisher`. (Some images also have a `promotion code` property.)
148142

149-
```azurecli
143+
```azurecli-interactive
150144
az vm image show --location westus --urn bitnami:rabbitmq:rabbitmq:latest
151145
```
152146
Output:
@@ -175,7 +169,7 @@ To deploy this image, you need to accept the terms and provide the purchase plan
175169

176170
To view and accept the license terms, use the [az vm image terms](/cli/azure/vm/image/terms) command. When you accept the terms, you enable programmatic deployment in your subscription. You only need to accept terms once per subscription for the image. For example:
177171

178-
```azurecli
172+
```azurecli-interactive
179173
az vm image terms show --urn bitnami:rabbitmq:rabbitmq:latest
180174
```
181175

@@ -200,7 +194,7 @@ The output includes a `licenseTextLink` to the license terms, and indicates that
200194

201195
To accept the terms, type:
202196

203-
```azurecli
197+
```azurecli-interactive
204198
az vm image terms accept --urn bitnami:rabbitmq:rabbitmq:latest
205199
```
206200

@@ -223,7 +217,7 @@ az vm create \
223217

224218
For an image with purchase plan parameters, like the RabbitMQ Certified by Bitnami image, you pass the URN for `--image` and also provide the purchase plan parameters:
225219

226-
```azurecli
220+
```azurecli-interactive
227221
az group create --name myPurchasePlanRG --location westus
228222
229223
az vm create \

0 commit comments

Comments
 (0)