GoogleCloudPlatform / cloud-ops-sandbox

Cloud Operations Sandbox is an open source collection of tools that helps practitioners to learn O11y and R9y practices from Google and apply them using Cloud Operations suite of tools.
Apache License 2.0
406 stars 148 forks source link

default VPC Requirement #1043

Open hasibeg opened 1 year ago

hasibeg commented 1 year ago

Thanks for stopping by to let us know something could be better!

Is your feature request related to a problem? Please describe. Sometimes the new projects don't have the default VPC network by default and the create script fails because GCE instances cannot be created.

Describe the solution you'd like It might be good to mention that "default" auto VPC is a pre-req for the script to create the sandbox environment

Describe alternatives you've considered Another alternative could be creating it as part of the terraform script if it doesn't exist.

Additional context

minherz commented 1 year ago

@hasibeg hello, thank you for your suggestion. we will add support for the custom network and subnetwork arguments in CLI (sandboxctl) in the next minor version (0.10).

lvaylet commented 1 year ago

@hasibeg I am in the same case, with an Org Policy removing the default VPC network from new projects. I have to create it manually, either from the console or with a gcloud command, then request a new provisioning.

@minherz These two options would definitely be good additions. I am not sure they solve the initial problem though. Delegating the creation of the default network to Terraform seems like a better, more seamless option.

lvaylet commented 1 year ago

@minherz @hasibeg I pushed #1052 to create the default network if it does not exist already, to ensure backward compatibility with a non-breaking change.

hasibeg commented 1 year ago

Thank you @lvaylet and the team for the update !

lvaylet commented 1 year ago

Fixed by #1052

minherz commented 1 year ago

It seems that when auto_create_subnetworks is omitted, the network is created without subnetworks. As a result, GKE cluster cannot be created because subnetworks are missing.