PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Wednesday, September 28, 2022

[FIXED] How to create google cloud instance in available zone?

 September 28, 2022     cloud, continuous-deployment, google-api, google-cloud-platform, google-compute-engine     No comments   

Issue

I have a scheduled builds and deployment of a project on UAT environment using Bamboo. Bamboo executes script to create google cloud instance and run the project inside created instance.

The problem is when I create instance using gcloud compute instances create myproject --image cos-stable-61-9765-79-0 --image-project cos-cloud --zone us-central1-b

I get the following error sometimes:

The zone 'projects/myproject/zones/us-central1-b' does not have enough resources available to fulfill the request. Try a different zone, or try again later.

I know resource availability in regions/zones are not publicly available.

My question is How can I create compute engine instances in resource available region/zones?


Solution

Like with many API issues, the answer is "retry". First, retry the request in the same zone as the issue might have only lasted a brief time as hinted at in the answer you linked. If a zone remains unavailable, retry with a different zone. There is almost always at least one zone in each region with enough capacity.



Answered By - David
Answer Checked By - Cary Denson (PHPFixing Admin)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing