How to change image family for existing image in google cloud compute?

It looks that unlike labels, image family cannot be changed after the creation of the image. It is so?

Upvotes: 2

Views: 2035

Answers (2)

sipickles
sipickles

Reputation: 1662

You have to create a new image from the existing one using gcloud with --source-image

gcloud compute images create ${PROD_IMAGE} --family=${PROD_FAMILY} \
  --source-image=${DEV_IMAGE} \
  --source-image-project=${GCP_PROJECT} --project=${GCP_PROJECT} 

Upvotes: 4

Will Faris
Will Faris

Reputation: 199

You can only update the cloud labels for an existing image.

Upvotes: 1

Related Questions