Skip to content

Commit 6ec5958

Browse files
Merge pull request docker#562 from classmarkets/machine-gce-image-family
machine/gce: explain how to use image families
2 parents 53d8efd + 5bde9b0 commit 6ec5958

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

machine/drivers/gce.md

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,21 @@ list of image URLs run:
5252

5353
gcloud compute images list --uri
5454

55+
Google Compute Engine supports [image families](https://cloud.google.com/compute/docs/images#image_families).
56+
An image family is like an image alias that always points to the latest image in the family. To create an
57+
instance from an image family, set `--google-machine-image` to the family's URL.
58+
59+
The following command will show images and which family they belong to (if any):
60+
61+
gcloud compute images list
62+
63+
To obtain a family URL, replace `<PROJECT>` and `<FAMILY>` in the following template.
64+
65+
https://www.googleapis.com/compute/v1/projects/<PROJECT>/global/images/family/<FAMILY>
66+
67+
For example, to create an instance from the latest Ubuntu 16 LTS image, specify
68+
`https://www.googleapis.com/compute/v1/projects/ubuntu-os-cloud/global/images/family/ubuntu-1604-lts`.
69+
5570
#### Environment variables and default values
5671

5772
| CLI option | Environment variable | Default |
@@ -68,4 +83,4 @@ list of image URLs run:
6883
| `--google-preemptible` | `GOOGLE_PREEMPTIBLE` | - |
6984
| `--google-tags` | `GOOGLE_TAGS` | - |
7085
| `--google-use-internal-ip` | `GOOGLE_USE_INTERNAL_IP` | - |
71-
| `--google-use-existing` | `GOOGLE_USE_EXISTING` | - |
86+
| `--google-use-existing` | `GOOGLE_USE_EXISTING` | - |

0 commit comments

Comments
 (0)