Uly.me

cloud engineer

  • Home
  • About
  • Archives
Home/Cloud/GCP Create Instance With Reservations

September 14, 2020

GCP Create Instance With Reservations

Here’s how to create an instance with CUD (committed used discounts) reservations.

gcloud compute instances create instance-name \
--no-address \
--private-network-ip 10.0.0.24 \
--source-machine-image=projects/project-id/global/machineImages/image-name \
--subnet=https://www.googleapis.com/compute/v1/projects/your-project/regions/us-central1/subnetworks/your-sub-network \
--machine-type=n1-standard-4 \
--reservation-affinity=specific \
--reservation=your-reservation-name \
--zone=us-central1-a \
--project=your-project-id

gcloud compute instances create instance-name \ --no-address \ --private-network-ip 10.0.0.24 \ --source-machine-image=projects/project-id/global/machineImages/image-name \ --subnet=https://www.googleapis.com/compute/v1/projects/your-project/regions/us-central1/subnetworks/your-sub-network \ --machine-type=n1-standard-4 \ --reservation-affinity=specific \ --reservation=your-reservation-name \ --zone=us-central1-a \ --project=your-project-id

Filed Under: Cloud Tagged With: compute, cud, gcp, reservations

Have content delivered to your mail. Subscribe below.

About Me

I'm Ulysses, Cloud Engineer at Cardinal Health based in Columbus. This blog is about Linux and Cloud technology. When off the grid, I enjoy riding my electric skateboard. I've surfed, snowboarded and played the saxophone in the past. I hope you find this website helpful. It's powered by WordPress and hosted on AWS LightSail.

  • Cloud
  • Linux
  • Git

Copyright © 2012–2021