From 841f856c7dadd6f0148dabdcdf3f61e77828a196 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Wed, 3 Dec 2025 22:11:15 -0500 Subject: [PATCH 1/8] terraform/gce: Re-organize Kconfig.compute Split the VM machine menu and the OS image menu into separate Kconfig files, as these two will each be generated by different scripts. Signed-off-by: Chuck Lever --- terraform/gce/Kconfig | 5 ++- terraform/gce/kconfigs/Kconfig.image | 37 ++++++++++++++++++ .../{Kconfig.compute => Kconfig.machine} | 38 ------------------- 3 files changed, 41 insertions(+), 39 deletions(-) create mode 100644 terraform/gce/kconfigs/Kconfig.image rename terraform/gce/kconfigs/{Kconfig.compute => Kconfig.machine} (72%) diff --git a/terraform/gce/Kconfig b/terraform/gce/Kconfig index 254fe6376..7c4c6141b 100644 --- a/terraform/gce/Kconfig +++ b/terraform/gce/Kconfig @@ -4,7 +4,10 @@ menu "Resource Location" source "terraform/gce/kconfigs/Kconfig.location" endmenu menu "Compute" -source "terraform/gce/kconfigs/Kconfig.compute" +comment "Machine selection" +source "terraform/gce/kconfigs/Kconfig.machine" +comment "OS image selection" +source "terraform/gce/kconfigs/Kconfig.image" endmenu menu "Storage" source "terraform/gce/kconfigs/Kconfig.storage" diff --git a/terraform/gce/kconfigs/Kconfig.image b/terraform/gce/kconfigs/Kconfig.image new file mode 100644 index 000000000..3477600ca --- /dev/null +++ b/terraform/gce/kconfigs/Kconfig.image @@ -0,0 +1,37 @@ +choice + prompt "OS Distributor" + default TERRAFORM_GCE_DISTRO_DEBIAN + help + Select the Linux distribution for the OS base image of the + instances to be created. + +config TERRAFORM_GCE_DISTRO_CENTOS + bool "CentOS" + +config TERRAFORM_GCE_DISTRO_DEBIAN + bool "Debian" + +config TERRAFORM_GCE_DISTRO_OL + bool "Oracle Linux" + +config TERRAFORM_GCE_DISTRO_OPENSUSE + bool "OpenSUSE" + +config TERRAFORM_GCE_DISTRO_RHEL + bool "Red Hat Enterprise Linux" + +config TERRAFORM_GCE_DISTRO_ROCKY + bool "Rocky Linux" + +config TERRAFORM_GCE_DISTRO_SLES + bool "SUSE Enterprise Linux Server" + +endchoice + +source "terraform/gce/kconfigs/images/Kconfig.centos" +source "terraform/gce/kconfigs/images/Kconfig.debian" +source "terraform/gce/kconfigs/images/Kconfig.oracle" +source "terraform/gce/kconfigs/images/Kconfig.opensuse" +source "terraform/gce/kconfigs/images/Kconfig.rhel" +source "terraform/gce/kconfigs/images/Kconfig.rocky" +source "terraform/gce/kconfigs/images/Kconfig.sles" diff --git a/terraform/gce/kconfigs/Kconfig.compute b/terraform/gce/kconfigs/Kconfig.machine similarity index 72% rename from terraform/gce/kconfigs/Kconfig.compute rename to terraform/gce/kconfigs/Kconfig.machine index b0c999293..707405c6e 100644 --- a/terraform/gce/kconfigs/Kconfig.compute +++ b/terraform/gce/kconfigs/Kconfig.machine @@ -71,41 +71,3 @@ source "terraform/gce/kconfigs/machines/Kconfig.c4-standard" source "terraform/gce/kconfigs/machines/Kconfig.c4a-standard" source "terraform/gce/kconfigs/machines/Kconfig.c4d-standard" source "terraform/gce/kconfigs/machines/Kconfig.a2-standard" - -choice - prompt "OS Distributor" - default TERRAFORM_GCE_DISTRO_DEBIAN - help - Select the Linux distribution for the OS base image of the - instances to be created. - -config TERRAFORM_GCE_DISTRO_CENTOS - bool "CentOS" - -config TERRAFORM_GCE_DISTRO_DEBIAN - bool "Debian" - -config TERRAFORM_GCE_DISTRO_OL - bool "Oracle Linux" - -config TERRAFORM_GCE_DISTRO_OPENSUSE - bool "OpenSUSE" - -config TERRAFORM_GCE_DISTRO_RHEL - bool "Red Hat Enterprise Linux" - -config TERRAFORM_GCE_DISTRO_ROCKY - bool "Rocky Linux" - -config TERRAFORM_GCE_DISTRO_SLES - bool "SUSE Enterprise Linux Server" - -endchoice - -source "terraform/gce/kconfigs/images/Kconfig.centos" -source "terraform/gce/kconfigs/images/Kconfig.debian" -source "terraform/gce/kconfigs/images/Kconfig.oracle" -source "terraform/gce/kconfigs/images/Kconfig.opensuse" -source "terraform/gce/kconfigs/images/Kconfig.rhel" -source "terraform/gce/kconfigs/images/Kconfig.rocky" -source "terraform/gce/kconfigs/images/Kconfig.sles" From bb0a632d6daa8dab011ea038592f0880c39a4d18 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2025 17:26:26 -0500 Subject: [PATCH 2/8] terraform/gce: Remove the kconfigs/zones subdirectory Instead of sourcing files in a subdirectory, move the content of those files right into Kconfig.location. This will make it easier to examine the differences between the current menu content and the dynamically-generated content. The pattern of multiple TERRAFORM_GCE_ZONE declarations is valid Kconfig since each is in a mutually exclusive if block (only one region can be active at a time). Signed-off-by: Chuck Lever --- terraform/gce/kconfigs/Kconfig.location | 409 +++++++++++++++++- .../gce/kconfigs/zones/Kconfig.asia-south1 | 27 -- .../gce/kconfigs/zones/Kconfig.asia-south2 | 27 -- .../zones/Kconfig.northamerica-northeast1 | 27 -- .../zones/Kconfig.northamerica-northeast2 | 27 -- .../zones/Kconfig.northamerica-south1 | 27 -- .../gce/kconfigs/zones/Kconfig.us-central1 | 31 -- terraform/gce/kconfigs/zones/Kconfig.us-east1 | 27 -- terraform/gce/kconfigs/zones/Kconfig.us-east4 | 27 -- terraform/gce/kconfigs/zones/Kconfig.us-east5 | 27 -- .../gce/kconfigs/zones/Kconfig.us-south1 | 27 -- terraform/gce/kconfigs/zones/Kconfig.us-west1 | 27 -- terraform/gce/kconfigs/zones/Kconfig.us-west2 | 27 -- terraform/gce/kconfigs/zones/Kconfig.us-west3 | 27 -- terraform/gce/kconfigs/zones/Kconfig.us-west4 | 27 -- 15 files changed, 395 insertions(+), 396 deletions(-) delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.asia-south1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.asia-south2 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast2 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.northamerica-south1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-central1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-east1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-east4 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-east5 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-south1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-west1 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-west2 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-west3 delete mode 100644 terraform/gce/kconfigs/zones/Kconfig.us-west4 diff --git a/terraform/gce/kconfigs/Kconfig.location b/terraform/gce/kconfigs/Kconfig.location index b2d8e8c49..fa8a16cf4 100644 --- a/terraform/gce/kconfigs/Kconfig.location +++ b/terraform/gce/kconfigs/Kconfig.location @@ -102,17 +102,398 @@ config TERRAFORM_GCE_REGION default "us-west3" if TERRAFORM_GCE_REGION_US_WEST3 default "us-west4" if TERRAFORM_GCE_REGION_US_WEST4 -source "terraform/gce/kconfigs/zones/Kconfig.asia-south1" -source "terraform/gce/kconfigs/zones/Kconfig.asia-south2" -source "terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast1" -source "terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast2" -source "terraform/gce/kconfigs/zones/Kconfig.northamerica-south1" -source "terraform/gce/kconfigs/zones/Kconfig.us-central1" -source "terraform/gce/kconfigs/zones/Kconfig.us-east1" -source "terraform/gce/kconfigs/zones/Kconfig.us-east4" -source "terraform/gce/kconfigs/zones/Kconfig.us-east5" -source "terraform/gce/kconfigs/zones/Kconfig.us-south1" -source "terraform/gce/kconfigs/zones/Kconfig.us-west1" -source "terraform/gce/kconfigs/zones/Kconfig.us-west2" -source "terraform/gce/kconfigs/zones/Kconfig.us-west3" -source "terraform/gce/kconfigs/zones/Kconfig.us-west4" +if TERRAFORM_GCE_REGION_ASIA_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_REGION_ASIA_SOUTH1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_REGION_ASIA_SOUTH1_A + bool "asia-south1-a" + +config TERRAFORM_GCE_REGION_ASIA_SOUTH1_B + bool "asia-south1-b" + +config TERRAFORM_GCE_REGION_ASIA_SOUTH1_C + bool "asia-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-south1-a" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_A + default "asia-south1-b" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_B + default "asia-south1-c" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_ASIA_SOUTH1 + +if TERRAFORM_GCE_REGION_ASIA_SOUTH2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_REGION_ASIA_SOUTH2_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_REGION_ASIA_SOUTH2_A + bool "asia-south2-a" + +config TERRAFORM_GCE_REGION_ASIA_SOUTH2_B + bool "asia-south2-b" + +config TERRAFORM_GCE_REGION_ASIA_SOUTH2_C + bool "asia-south2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-south2-a" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_A + default "asia-south2-b" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_B + default "asia-south2-c" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_C + +endif # TERRAFORM_GCE_REGION_ASIA_SOUTH2 + +if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_A + bool "northamerica-northeast1-a" + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B + bool "northamerica-northeast1-b" + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_C + bool "northamerica-northeast1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "northamerica-northeast1-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_A + default "northamerica-northeast1-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B + default "northamerica-northeast1-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_C + +endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 + +if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_A + bool "northamerica-northeast2-a" + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B + bool "northamerica-northeast2-b" + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_C + bool "northamerica-northeast2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "northamerica-northeast2-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_A + default "northamerica-northeast2-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B + default "northamerica-northeast2-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_C + +endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 + +if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_A + bool "northamerica-south1-a" + +config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B + bool "northamerica-south1-b" + +config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_C + bool "northamerica-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "northamerica-south1-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_A + default "northamerica-south1-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B + default "northamerica-south1-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 + +if TERRAFORM_GCE_REGION_US_CENTRAL1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_CENTRAL1_C + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_A + bool "us-central1-a" + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_B + bool "us-central1-b" + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_C + bool "us-central1-c" + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_F + bool "us-central1-f" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-central1-a" if TERRAFORM_GCE_ZONE_US_CENTRAL1_A + default "us-central1-b" if TERRAFORM_GCE_ZONE_US_CENTRAL1_B + default "us-central1-c" if TERRAFORM_GCE_ZONE_US_CENTRAL1_C + default "us-central1-f" if TERRAFORM_GCE_ZONE_US_CENTRAL1_F + +endif # TERRAFORM_GCE_REGION_US_CENTRAL1 + +if TERRAFORM_GCE_REGION_US_EAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_EAST1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_EAST1_B + bool "us-east1-b" + +config TERRAFORM_GCE_ZONE_US_EAST1_C + bool "us-east1-c" + +config TERRAFORM_GCE_ZONE_US_EAST1_D + bool "us-east1-d" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-east1-b" if TERRAFORM_GCE_ZONE_US_EAST1_B + default "us-east1-c" if TERRAFORM_GCE_ZONE_US_EAST1_C + default "us-east1-d" if TERRAFORM_GCE_ZONE_US_EAST1_D + +endif # TERRAFORM_GCE_REGION_US_EAST1 + +if TERRAFORM_GCE_REGION_US_EAST4 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_EAST4_C + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_EAST4_A + bool "us-east4-a" + +config TERRAFORM_GCE_ZONE_US_EAST4_B + bool "us-east4-b" + +config TERRAFORM_GCE_ZONE_US_EAST4_C + bool "us-east4-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-east4-a" if TERRAFORM_GCE_ZONE_US_EAST4_A + default "us-east4-b" if TERRAFORM_GCE_ZONE_US_EAST4_B + default "us-east4-c" if TERRAFORM_GCE_ZONE_US_EAST4_C + +endif # TERRAFORM_GCE_REGION_US_EAST4 + +if TERRAFORM_GCE_REGION_US_EAST5 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_EAST5_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_EAST5_A + bool "us-east5-a" + +config TERRAFORM_GCE_ZONE_US_EAST5_B + bool "us-east5-b" + +config TERRAFORM_GCE_ZONE_US_EAST5_C + bool "us-east5-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-east5-a" if TERRAFORM_GCE_ZONE_US_EAST5_A + default "us-east5-b" if TERRAFORM_GCE_ZONE_US_EAST5_B + default "us-east5-c" if TERRAFORM_GCE_ZONE_US_EAST5_C + +endif # TERRAFORM_GCE_REGION_US_EAST5 + +if TERRAFORM_GCE_REGION_US_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_SOUTH1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_SOUTH1_A + bool "us-south1-a" + +config TERRAFORM_GCE_ZONE_US_SOUTH1_B + bool "us-south1-b" + +config TERRAFORM_GCE_ZONE_US_SOUTH1_C + bool "us-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-south1-a" if TERRAFORM_GCE_ZONE_US_SOUTH1_A + default "us-south1-b" if TERRAFORM_GCE_ZONE_US_SOUTH1_B + default "us-south1-c" if TERRAFORM_GCE_ZONE_US_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_US_SOUTH1 + +if TERRAFORM_GCE_REGION_US_WEST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST1_A + bool "us-west1-a" + +config TERRAFORM_GCE_ZONE_US_WEST1_B + bool "us-west1-b" + +config TERRAFORM_GCE_ZONE_US_WEST1_C + bool "us-west1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west1-a" if TERRAFORM_GCE_ZONE_US_WEST1_A + default "us-west1-b" if TERRAFORM_GCE_ZONE_US_WEST1_B + default "us-west1-c" if TERRAFORM_GCE_ZONE_US_WEST1_C + +endif # TERRAFORM_GCE_REGION_US_WEST1 + +if TERRAFORM_GCE_REGION_US_WEST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST2_C + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST2_A + bool "us-west2-a" + +config TERRAFORM_GCE_ZONE_US_WEST2_B + bool "us-west2-b" + +config TERRAFORM_GCE_ZONE_US_WEST2_C + bool "us-west2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west2-a" if TERRAFORM_GCE_ZONE_US_WEST2_A + default "us-west2-b" if TERRAFORM_GCE_ZONE_US_WEST2_B + default "us-west2-c" if TERRAFORM_GCE_ZONE_US_WEST2_C + +endif # TERRAFORM_GCE_REGION_US_WEST2 + +if TERRAFORM_GCE_REGION_US_WEST3 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST3_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST3_A + bool "us-west3-a" + +config TERRAFORM_GCE_ZONE_US_WEST3_B + bool "us-west3-b" + +config TERRAFORM_GCE_ZONE_US_WEST3_C + bool "us-west3-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west3-a" if TERRAFORM_GCE_ZONE_US_WEST3_A + default "us-west3-b" if TERRAFORM_GCE_ZONE_US_WEST3_B + default "us-west3-c" if TERRAFORM_GCE_ZONE_US_WEST3_C + +endif # TERRAFORM_GCE_REGION_US_WEST3 + +if TERRAFORM_GCE_REGION_US_WEST4 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST4_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST4_A + bool "us-west4-a" + +config TERRAFORM_GCE_ZONE_US_WEST4_B + bool "us-west4-b" + +config TERRAFORM_GCE_ZONE_US_WEST4_C + bool "us-west4-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west4-a" if TERRAFORM_GCE_ZONE_US_WEST4_A + default "us-west4-b" if TERRAFORM_GCE_ZONE_US_WEST4_B + default "us-west4-c" if TERRAFORM_GCE_ZONE_US_WEST4_C + +endif # TERRAFORM_GCE_REGION_US_WEST4 diff --git a/terraform/gce/kconfigs/zones/Kconfig.asia-south1 b/terraform/gce/kconfigs/zones/Kconfig.asia-south1 deleted file mode 100644 index 48082b899..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.asia-south1 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_ASIA_SOUTH1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_ASIA_SOUTH1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1_A - bool "asia-south1-a" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1_B - bool "asia-south1-b" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1_C - bool "asia-south1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "asia-south1-a" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_A - default "asia-south1-b" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_B - default "asia-south1-c" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_C - -endif # TERRAFORM_GCE_REGION_ASIA_SOUTH1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.asia-south2 b/terraform/gce/kconfigs/zones/Kconfig.asia-south2 deleted file mode 100644 index 9a7775f3d..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.asia-south2 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_ASIA_SOUTH2 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_ASIA_SOUTH2_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2_A - bool "asia-south2-a" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2_B - bool "asia-south2-b" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2_C - bool "asia-south2-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "asia-south2-a" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_A - default "asia-south2-b" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_B - default "asia-south2-c" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_C - -endif # TERRAFORM_GCE_REGION_ASIA_SOUTH2 diff --git a/terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast1 b/terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast1 deleted file mode 100644 index 38e926644..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast1 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_A - bool "northamerica-northeast1-a" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B - bool "northamerica-northeast1-b" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_C - bool "northamerica-northeast1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "northamerica-northeast1-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_A - default "northamerica-northeast1-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B - default "northamerica-northeast1-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_C - -endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast2 b/terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast2 deleted file mode 100644 index be80e7152..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.northamerica-northeast2 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_A - bool "northamerica-northeast2-a" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B - bool "northamerica-northeast2-b" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_C - bool "northamerica-northeast2-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "northamerica-northeast2-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_A - default "northamerica-northeast2-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B - default "northamerica-northeast2-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_C - -endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 diff --git a/terraform/gce/kconfigs/zones/Kconfig.northamerica-south1 b/terraform/gce/kconfigs/zones/Kconfig.northamerica-south1 deleted file mode 100644 index 5c67d61e2..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.northamerica-south1 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_A - bool "northamerica-south1-a" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B - bool "northamerica-south1-b" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_C - bool "northamerica-south1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "northamerica-south1-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_A - default "northamerica-south1-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B - default "northamerica-south1-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_C - -endif # TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-central1 b/terraform/gce/kconfigs/zones/Kconfig.us-central1 deleted file mode 100644 index a7f21316e..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-central1 +++ /dev/null @@ -1,31 +0,0 @@ -if TERRAFORM_GCE_REGION_US_CENTRAL1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_CENTRAL1_C - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_A - bool "us-central1-a" - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_B - bool "us-central1-b" - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_C - bool "us-central1-c" - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_F - bool "us-central1-f" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-central1-a" if TERRAFORM_GCE_ZONE_US_CENTRAL1_A - default "us-central1-b" if TERRAFORM_GCE_ZONE_US_CENTRAL1_B - default "us-central1-c" if TERRAFORM_GCE_ZONE_US_CENTRAL1_C - default "us-central1-f" if TERRAFORM_GCE_ZONE_US_CENTRAL1_F - -endif # TERRAFORM_GCE_REGION_US_CENTRAL1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-east1 b/terraform/gce/kconfigs/zones/Kconfig.us-east1 deleted file mode 100644 index 90966495f..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-east1 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_EAST1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_EAST1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_EAST1_B - bool "us-east1-b" - -config TERRAFORM_GCE_ZONE_US_EAST1_C - bool "us-east1-c" - -config TERRAFORM_GCE_ZONE_US_EAST1_D - bool "us-east1-d" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-east1-b" if TERRAFORM_GCE_ZONE_US_EAST1_B - default "us-east1-c" if TERRAFORM_GCE_ZONE_US_EAST1_C - default "us-east1-d" if TERRAFORM_GCE_ZONE_US_EAST1_D - -endif # TERRAFORM_GCE_REGION_US_EAST1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-east4 b/terraform/gce/kconfigs/zones/Kconfig.us-east4 deleted file mode 100644 index d33eb1148..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-east4 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_EAST4 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_EAST4_C - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_EAST4_A - bool "us-east4-a" - -config TERRAFORM_GCE_ZONE_US_EAST4_B - bool "us-east4-b" - -config TERRAFORM_GCE_ZONE_US_EAST4_C - bool "us-east4-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-east4-a" if TERRAFORM_GCE_ZONE_US_EAST4_A - default "us-east4-b" if TERRAFORM_GCE_ZONE_US_EAST4_B - default "us-east4-c" if TERRAFORM_GCE_ZONE_US_EAST4_C - -endif # TERRAFORM_GCE_REGION_US_EAST4 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-east5 b/terraform/gce/kconfigs/zones/Kconfig.us-east5 deleted file mode 100644 index 975ccafd8..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-east5 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_EAST5 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_EAST5_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_EAST5_A - bool "us-east5-a" - -config TERRAFORM_GCE_ZONE_US_EAST5_B - bool "us-east5-b" - -config TERRAFORM_GCE_ZONE_US_EAST5_C - bool "us-east5-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-east5-a" if TERRAFORM_GCE_ZONE_US_EAST5_A - default "us-east5-b" if TERRAFORM_GCE_ZONE_US_EAST5_B - default "us-east5-c" if TERRAFORM_GCE_ZONE_US_EAST5_C - -endif # TERRAFORM_GCE_REGION_US_EAST5 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-south1 b/terraform/gce/kconfigs/zones/Kconfig.us-south1 deleted file mode 100644 index 8377adcc7..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-south1 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_SOUTH1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_SOUTH1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_SOUTH1_A - bool "us-south1-a" - -config TERRAFORM_GCE_ZONE_US_SOUTH1_B - bool "us-south1-b" - -config TERRAFORM_GCE_ZONE_US_SOUTH1_C - bool "us-south1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-south1-a" if TERRAFORM_GCE_ZONE_US_SOUTH1_A - default "us-south1-b" if TERRAFORM_GCE_ZONE_US_SOUTH1_B - default "us-south1-c" if TERRAFORM_GCE_ZONE_US_SOUTH1_C - -endif # TERRAFORM_GCE_REGION_US_SOUTH1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-west1 b/terraform/gce/kconfigs/zones/Kconfig.us-west1 deleted file mode 100644 index f44080dde..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-west1 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_WEST1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST1_A - bool "us-west1-a" - -config TERRAFORM_GCE_ZONE_US_WEST1_B - bool "us-west1-b" - -config TERRAFORM_GCE_ZONE_US_WEST1_C - bool "us-west1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west1-a" if TERRAFORM_GCE_ZONE_US_WEST1_A - default "us-west1-b" if TERRAFORM_GCE_ZONE_US_WEST1_B - default "us-west1-c" if TERRAFORM_GCE_ZONE_US_WEST1_C - -endif # TERRAFORM_GCE_REGION_US_WEST1 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-west2 b/terraform/gce/kconfigs/zones/Kconfig.us-west2 deleted file mode 100644 index 9c97c1a79..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-west2 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_WEST2 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST2_C - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST2_A - bool "us-west2-a" - -config TERRAFORM_GCE_ZONE_US_WEST2_B - bool "us-west2-b" - -config TERRAFORM_GCE_ZONE_US_WEST2_C - bool "us-west2-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west2-a" if TERRAFORM_GCE_ZONE_US_WEST2_A - default "us-west2-b" if TERRAFORM_GCE_ZONE_US_WEST2_B - default "us-west2-c" if TERRAFORM_GCE_ZONE_US_WEST2_C - -endif # TERRAFORM_GCE_REGION_US_WEST2 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-west3 b/terraform/gce/kconfigs/zones/Kconfig.us-west3 deleted file mode 100644 index 13c4c899c..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-west3 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_WEST3 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST3_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST3_A - bool "us-west3-a" - -config TERRAFORM_GCE_ZONE_US_WEST3_B - bool "us-west3-b" - -config TERRAFORM_GCE_ZONE_US_WEST3_C - bool "us-west3-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west3-a" if TERRAFORM_GCE_ZONE_US_WEST3_A - default "us-west3-b" if TERRAFORM_GCE_ZONE_US_WEST3_B - default "us-west3-c" if TERRAFORM_GCE_ZONE_US_WEST3_C - -endif # TERRAFORM_GCE_REGION_US_WEST3 diff --git a/terraform/gce/kconfigs/zones/Kconfig.us-west4 b/terraform/gce/kconfigs/zones/Kconfig.us-west4 deleted file mode 100644 index 1419c6d7b..000000000 --- a/terraform/gce/kconfigs/zones/Kconfig.us-west4 +++ /dev/null @@ -1,27 +0,0 @@ -if TERRAFORM_GCE_REGION_US_WEST4 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST4_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST4_A - bool "us-west4-a" - -config TERRAFORM_GCE_ZONE_US_WEST4_B - bool "us-west4-b" - -config TERRAFORM_GCE_ZONE_US_WEST4_C - bool "us-west4-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west4-a" if TERRAFORM_GCE_ZONE_US_WEST4_A - default "us-west4-b" if TERRAFORM_GCE_ZONE_US_WEST4_B - default "us-west4-c" if TERRAFORM_GCE_ZONE_US_WEST4_C - -endif # TERRAFORM_GCE_REGION_US_WEST4 From 3fae9aacc27ff48391d7ae452de56f2b61c03159 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2025 17:03:27 -0500 Subject: [PATCH 3/8] terraform/gce: Inline kconfigs/machines subdirectory into Kconfig.machine Instead of sourcing files in a subdirectory, move the content of those files right into Kconfig.machine. This will make it easier to examine the differences between the current menu content and the dynamically-generated content. Signed-off-by: Chuck Lever --- terraform/gce/kconfigs/Kconfig.machine | 954 +++++++++++++++++- .../gce/kconfigs/machines/Kconfig.a2-standard | 56 - .../gce/kconfigs/machines/Kconfig.c3-standard | 41 - .../kconfigs/machines/Kconfig.c3d-standard | 46 - .../gce/kconfigs/machines/Kconfig.c4-standard | 58 -- .../kconfigs/machines/Kconfig.c4a-standard | 57 -- .../kconfigs/machines/Kconfig.c4d-standard | 51 - .../gce/kconfigs/machines/Kconfig.e2-highcpu | 58 -- .../gce/kconfigs/machines/Kconfig.e2-standard | 58 -- .../gce/kconfigs/machines/Kconfig.n1-highcpu | 55 - .../gce/kconfigs/machines/Kconfig.n1-standard | 61 -- .../gce/kconfigs/machines/Kconfig.n2-highcpu | 56 - .../gce/kconfigs/machines/Kconfig.n2-standard | 56 - .../gce/kconfigs/machines/Kconfig.n2d-highcpu | 57 -- .../kconfigs/machines/Kconfig.n2d-standard | 57 -- .../gce/kconfigs/machines/Kconfig.n4-highcpu | 51 - .../gce/kconfigs/machines/Kconfig.n4-standard | 51 - 17 files changed, 938 insertions(+), 885 deletions(-) delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.a2-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.c3-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.c3d-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.c4-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.c4a-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.c4d-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.e2-highcpu delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.e2-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n1-highcpu delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n1-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n2-highcpu delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n2-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n2d-highcpu delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n2d-standard delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n4-highcpu delete mode 100644 terraform/gce/kconfigs/machines/Kconfig.n4-standard diff --git a/terraform/gce/kconfigs/Kconfig.machine b/terraform/gce/kconfigs/Kconfig.machine index 707405c6e..07e06233e 100644 --- a/terraform/gce/kconfigs/Kconfig.machine +++ b/terraform/gce/kconfigs/Kconfig.machine @@ -47,27 +47,949 @@ config TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU help General purpose computing on Intel Emerald Rapids CPUs. +config TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU + bool "E2 High CPU family" + depends on TARGET_ARCH_X86_64 + help + Cost-effective computing on Intel/AMD EPYC processors. + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD + bool "E2 Standard family" + depends on TARGET_ARCH_X86_64 + help + Cost-effective computing on Intel/AMD EPYC processors. + +config TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU + bool "N1 High CPU family" + depends on TARGET_ARCH_X86_64 + help + Balanced performance and cost-effectiveness. Intel CPUs. + +config TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD + bool "C3 Standard family" + depends on TARGET_ARCH_X86_64 + help + High performance on Intel Sapphire Rapids CPUs. + +config TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD + bool "C3D Standard family" + depends on TARGET_ARCH_X86_64 + help + High performance on AMD EPYC Genoa CPUs. + config TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD bool "C4 Standard family" depends on TARGET_ARCH_X86_64 help Consistently high performance on Intel Emerald Rapids CPUs. +config TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD + bool "C4A Standard family" + depends on TARGET_ARCH_ARM64 + help + High performance on Google Axion Arm-based processors. + +config TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD + bool "C4D Standard family" + depends on TARGET_ARCH_X86_64 + help + High performance on AMD EPYC Turin CPUs. + +config TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU + bool "A2 High GPU family" + depends on TARGET_ARCH_X86_64 + help + GPU-accelerated computing with NVIDIA A100 GPUs. + +endchoice + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 + help + The E2 machine series offers both Intel and AMD EPYC + processors, selected for you at the time of VM creation. + Machine types in this series are available in all regions + and zones and support a virtio memory balloon device. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 + bool "e2-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 + bool "e2-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 + bool "e2-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 + bool "e2-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 + bool "e2-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 32GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-highcpu-2" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 + default "e2-highcpu-4" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 + default "e2-highcpu-8" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 + default "e2-highcpu-16" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 + default "e2-highcpu-32" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_STANDARD_8 + help + The E2 machine series offers both Intel and AMD EPYC + processors, selected for you at the time of VM creation. + Machine types in this series are available in all regions + and zones and support a virtio memory balloon device. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_2 + bool "e2-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_4 + bool "e2-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_8 + bool "e2-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_16 + bool "e2-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_32 + bool "e2-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-standard-2" if TERRAFORM_GCE_MACHINE_E2_STANDARD_2 + default "e2-standard-4" if TERRAFORM_GCE_MACHINE_E2_STANDARD_4 + default "e2-standard-8" if TERRAFORM_GCE_MACHINE_E2_STANDARD_8 + default "e2-standard-16" if TERRAFORM_GCE_MACHINE_E2_STANDARD_16 + default "e2-standard-32" if TERRAFORM_GCE_MACHINE_E2_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N1_STANDARD_8 + help + The N1 machine series is Compute Engine's first generation + general-purpose machine series available on Intel Skylake, + Broadwell, Haswell, Sandy Bridge, and Ivy Bridge CPU + platforms. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_1 + bool "n1-standard-1" + help + 1 vCPU and 3.75GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_2 + bool "n1-standard-2" + help + 2 vCPUs (1 core) and 7.5GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_4 + bool "n1-standard-4" + help + 4 vCPUs (2 cores) and 15GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_8 + bool "n1-standard-8" + help + 8 vCPUs (4 cores) and 30GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_16 + bool "n1-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 60GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_32 + bool "n1-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 120GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n1-standard-1" if TERRAFORM_GCE_MACHINE_N1_STANDARD_1 + default "n1-standard-2" if TERRAFORM_GCE_MACHINE_N1_STANDARD_2 + default "n1-standard-4" if TERRAFORM_GCE_MACHINE_N1_STANDARD_4 + default "n1-standard-8" if TERRAFORM_GCE_MACHINE_N1_STANDARD_8 + default "n1-standard-16" if TERRAFORM_GCE_MACHINE_N1_STANDARD_16 + default "n1-standard-32" if TERRAFORM_GCE_MACHINE_N1_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 + help + The N1 machine series is Compute Engine's first generation + general-purpose machine series available on Intel Skylake, + Broadwell, Haswell, Sandy Bridge, and Ivy Bridge CPU + platforms. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 + bool "n1-highcpu-2" + help + 2 vCPUs (1 core) and 1.8GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 + bool "n1-highcpu-4" + help + 4 vCPUs (2 cores) and 3.6GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 + bool "n1-highcpu-8" + help + 8 vCPUs (4 cores) and 7.2GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 + bool "n1-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 14.4GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 + bool "n1-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 28.8GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n1-highcpu-2" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 + default "n1-highcpu-4" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 + default "n1-highcpu-8" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 + default "n1-highcpu-16" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 + default "n1-highcpu-32" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2_STANDARD_8 + help + The N2 machine series can run on either Intel Cascade Lake + (on smaller configurations) or Intel Ice Lake. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_2 + bool "n2-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_4 + bool "n2-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_8 + bool "n2-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_16 + bool "n2-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_32 + bool "n2-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2-standard-2" if TERRAFORM_GCE_MACHINE_N2_STANDARD_2 + default "n2-standard-4" if TERRAFORM_GCE_MACHINE_N2_STANDARD_4 + default "n2-standard-8" if TERRAFORM_GCE_MACHINE_N2_STANDARD_8 + default "n2-standard-16" if TERRAFORM_GCE_MACHINE_N2_STANDARD_16 + default "n2-standard-32" if TERRAFORM_GCE_MACHINE_N2_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 + help + The N2 machine series can run on either Intel Cascade Lake + (on smaller configurations) or Intel Ice Lake. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 + bool "n2-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 + bool "n2-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 + bool "n2-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 + bool "n2-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 + bool "n2-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 32GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2-highcpu-2" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 + default "n2-highcpu-4" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 + default "n2-highcpu-8" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 + default "n2-highcpu-16" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 + default "n2-highcpu-32" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 + help + The N2D machine series can run on either AMD EPYC Milan or + AMD EPYC Rome processors. The third generation AMD EPYC + Milan processor is available only in specific regions and zones. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 + bool "n2d-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 + bool "n2d-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 + bool "n2d-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 + bool "n2d-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 + bool "n2d-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2d-standard-2" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 + default "n2d-standard-4" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 + default "n2d-standard-8" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 + default "n2d-standard-16" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 + default "n2d-standard-32" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 + help + The N2D machine series can run on either AMD EPYC Milan or + AMD EPYC Rome processors. The third generation AMD EPYC + Milan processor is available only in specific regions and zones. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 + bool "n2d-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 + bool "n2d-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 + bool "n2d-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 + bool "n2d-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 + bool "n2d-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 32GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2d-highcpu-2" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 + default "n2d-highcpu-4" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 + default "n2d-highcpu-8" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 + default "n2d-highcpu-16" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 + default "n2d-highcpu-32" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_N4_STANDARD_4 + help + N4 VMs are powered by the 5th generation Intel Xeon Scalable + processors (code-named Emerald Rapids) and Titanium. + +config TERRAFORM_GCE_MACHINE_N4_STANDARD_2 + bool "n4-standard-2" + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_STANDARD_4 + bool "n4-standard-4" + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_STANDARD_8 + bool "n4-standard-8" + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_STANDARD_16 + bool "n4-standard-16" + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_STANDARD_32 + bool "n4-standard-32" + help + 32 vCPUs (16 cores) and 128GB of memory. + endchoice -source "terraform/gce/kconfigs/machines/Kconfig.e2-highcpu" -source "terraform/gce/kconfigs/machines/Kconfig.e2-standard" -source "terraform/gce/kconfigs/machines/Kconfig.n1-standard" -source "terraform/gce/kconfigs/machines/Kconfig.n1-highcpu" -source "terraform/gce/kconfigs/machines/Kconfig.n2-standard" -source "terraform/gce/kconfigs/machines/Kconfig.n2-highcpu" -source "terraform/gce/kconfigs/machines/Kconfig.n2d-standard" -source "terraform/gce/kconfigs/machines/Kconfig.n2d-highcpu" -source "terraform/gce/kconfigs/machines/Kconfig.n4-standard" -source "terraform/gce/kconfigs/machines/Kconfig.n4-highcpu" -source "terraform/gce/kconfigs/machines/Kconfig.c3-standard" -source "terraform/gce/kconfigs/machines/Kconfig.c3d-standard" -source "terraform/gce/kconfigs/machines/Kconfig.c4-standard" -source "terraform/gce/kconfigs/machines/Kconfig.c4a-standard" -source "terraform/gce/kconfigs/machines/Kconfig.c4d-standard" -source "terraform/gce/kconfigs/machines/Kconfig.a2-standard" +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n4-standard-2" if TERRAFORM_GCE_MACHINE_N4_STANDARD_2 + default "n4-standard-4" if TERRAFORM_GCE_MACHINE_N4_STANDARD_4 + default "n4-standard-8" if TERRAFORM_GCE_MACHINE_N4_STANDARD_8 + default "n4-standard-16" if TERRAFORM_GCE_MACHINE_N4_STANDARD_16 + default "n4-standard-32" if TERRAFORM_GCE_MACHINE_N4_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 + help + N4 VMs are powered by the 5th generation Intel Xeon Scalable + processors (code-named Emerald Rapids) and Titanium. + +config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_2 + bool "n4-highcpu-2" + help + 2 vCPUs (1 core) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 + bool "n4-highcpu-4" + help + 4 vCPUs (2 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_8 + bool "n4-highcpu-8" + help + 8 vCPUs (4 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_16 + bool "n4-highcpu-16" + help + 16 vCPUs (8 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_32 + bool "n4-highcpu-32" + help + 32 vCPUs (16 cores) and 64GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n4-highcpu-2" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_2 + default "n4-highcpu-4" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 + default "n4-highcpu-8" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_8 + default "n4-highcpu-16" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_16 + default "n4-highcpu-32" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_C3_STANDARD_4 + help + C3 VMs are powered by the 4th generation Intel Xeon + Scalable processors (code-named Sapphire Rapids), DDR5 + memory, and Titanium, enabling higher levels of networking + performance, isolation and security. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_4 + bool "c3-standard-4" + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_8 + bool "c3-standard-8" + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_22 + bool "c3-standard-22" + help + 22 vCPUs (11 cores) and 88GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c3-standard-4" if TERRAFORM_GCE_MACHINE_C3_STANDARD_4 + default "c3-standard-8" if TERRAFORM_GCE_MACHINE_C3_STANDARD_8 + default "c3-standard-22" if TERRAFORM_GCE_MACHINE_C3_STANDARD_22 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 + help + C3D VMs are powered by the 4th-gen AMD EPYC (Genoa) + processor. C3D uses Titanium, enabling higher levels + of networking performance, isolation and security. + +config TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 + bool "c3d-standard-4" + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_STANDARD_8 + bool "c3d-standard-8" + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_STANDARD_16 + bool "c3d-standard-16" + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_STANDARD_30 + bool "c3d-standard-30" + help + 30 vCPUs (15 cores) and 120GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c3d-standard-4" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 + default "c3d-standard-8" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_8 + default "c3d-standard-16" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_16 + default "c3d-standard-30" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_30 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_C4_STANDARD_4 + help + C4 VMs are powered by 6th generation (code-named Granite + Rapids) or 5th generation (code-named Emerald Rapids) + Intel Xeon Scalable processors and Titanium. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_2 + bool "c4-standard-2" + help + 2 vCPUs (1 core) and 7GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_4 + bool "c4-standard-4" + help + 4 vCPUs (2 cores) and 15GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_8 + bool "c4-standard-8" + help + 8 vCPUs (4 cores) and 30GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_16 + bool "c4-standard-16" + help + 16 vCPUs (8 cores) and 60GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_24 + bool "c4-standard-24" + help + 24 vCPUs (12 cores) and 90GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_32 + bool "c4-standard-32" + help + 32 vCPUs (16 cores) and 120GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4-standard-2" if TERRAFORM_GCE_MACHINE_C4_STANDARD_2 + default "c4-standard-4" if TERRAFORM_GCE_MACHINE_C4_STANDARD_4 + default "c4-standard-8" if TERRAFORM_GCE_MACHINE_C4_STANDARD_8 + default "c4-standard-16" if TERRAFORM_GCE_MACHINE_C4_STANDARD_16 + default "c4-standard-24" if TERRAFORM_GCE_MACHINE_C4_STANDARD_24 + default "c4-standard-32" if TERRAFORM_GCE_MACHINE_C4_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 + help + C4A VMs are powered by Google's first Arm-based Axion™ + processor, DDR5 memory, and local Titanium SSDs. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 + bool "c4a-standard-1" + help + 1 vCPU and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 + bool "c4a-standard-2" + help + 2 vCPUs and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 + bool "c4a-standard-4" + help + 4 vCPUs and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 + bool "c4a-standard-8" + help + 8 vCPUs and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 + bool "c4a-standard-16" + help + 16 vCPUs and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 + bool "c4a-standard-32" + help + 32 vCPUs and 128GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4a-standard-1" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 + default "c4a-standard-2" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 + default "c4a-standard-4" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 + default "c4a-standard-8" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 + default "c4a-standard-16" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 + default "c4a-standard-32" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 + help + C4D VMs are powered by the fifth generation AMD EPYC Turin + processor and Titanium. + +config TERRAFORM_GCE_MACHINE_C4D_STANDARD_2 + bool "c4d-standard-2" + help + 2 vCPUs (1 core) and 7GB of memory. + +config TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 + bool "c4d-standard-4" + help + 4 vCPUs (2 cores) and 15GB of memory. + +config TERRAFORM_GCE_MACHINE_C4D_STANDARD_8 + bool "c4d-standard-8" + help + 8 vCPUs (4 cores) and 31GB of memory. + +config TERRAFORM_GCE_MACHINE_C4D_STANDARD_16 + bool "c4d-standard-16" + help + 16 vCPUs (8 cores) and 62GB of memory. + +config TERRAFORM_GCE_MACHINE_C4D_STANDARD_24 + bool "c4d-standard-24" + help + 24 vCPUs (12 cores) and 93GB of memory. + +config TERRAFORM_GCE_MACHINE_C4D_STANDARD_32 + bool "c4d-standard-32" + help + 32 vCPUs (16 cores) and 124GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4d-standard-2" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_2 + default "c4d-standard-4" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 + default "c4d-standard-8" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_8 + default "c4d-standard-16" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_16 + default "c4d-standard-24" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_24 + default "c4d-standard-32" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "hyperdisk-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU + +choice + prompt "GCE Machine Type" + default TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G + help + A2 High GPU machine types have a fixed number of A100 + 40GB GPUs. + +config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G + bool "a2-highgpu-1g" + help + 12 vCPUs, 85GB of memory, and 1 GPU with 40GB of GPU + memory. + +config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_2G + bool "a2-highgpu-2g" + help + 24 vCPUs, 170GB of memory, and 2 GPUs with 80GB of GPU + memory. + +config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_4G + bool "a2-highgpu-4g" + help + 48 vCPUs, 340GB of memory, and 4 GPUs with 160GB of GPU + memory. + +config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_8G + bool "a2-highgpu-8g" + help + 96 vCPUs, 680GB of memory, and 8 GPUs with 320GB of GPU + memory. + +config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_16G + bool "a2-highgpu-16g" + help + 96 vCPUs, 1360GB of memory, and 16 GPUs with 640GB of GPU + memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "a2-highgpu-1g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G + default "a2-highgpu-2g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_2G + default "a2-highgpu-4g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_4G + default "a2-highgpu-8g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_8G + default "a2-highgpu-16g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_16G + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.a2-standard b/terraform/gce/kconfigs/machines/Kconfig.a2-standard deleted file mode 100644 index 5e54db36b..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.a2-standard +++ /dev/null @@ -1,56 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G - help - A2 High GPU machine types have a fixed number of A100 - 40GB GPUs. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G - bool "a2-highgpu-1g" - help - 12 vCPUs, 85GB of memory, and 1 GPU with 40GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_2G - bool "a2-highgpu-2g" - help - 24 vCPUs, 170GB of memory, and 2 GPUs with 80GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_4G - bool "a2-highgpu-4g" - help - 48 vCPUs, 340GB of memory, and 4 GPUs with 160GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_8G - bool "a2-highgpu-8g" - help - 96 vCPUs, 680GB of memory, and 8 GPUs with 320GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_16G - bool "a2-highgpu-16g" - help - 96 vCPUs, 1360GB of memory, and 16 GPUs with 640GB of GPU - memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "a2-highgpu-1g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G - default "a2-highgpu-2g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_2G - default "a2-highgpu-4g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_4G - default "a2-highgpu-8g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_8G - default "a2-highgpu-16g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_16G - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.c3-standard b/terraform/gce/kconfigs/machines/Kconfig.c3-standard deleted file mode 100644 index 183ac315c..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.c3-standard +++ /dev/null @@ -1,41 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C3_STANDARD_4 - help - C3 VMs are powered by the 4th generation Intel Xeon - Scalable processors (code-named Sapphire Rapids), DDR5 - memory, and Titanium, enabling higher levels of networking - performance, isolation and security. - -config TERRAFORM_GCE_MACHINE_C3_STANDARD_4 - bool "c3-standard-4" - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_C3_STANDARD_8 - bool "c3-standard-8" - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_C3_STANDARD_22 - bool "c3-standard-22" - help - 22 vCPUs (11 cores) and 88GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c3-standard-4" if TERRAFORM_GCE_MACHINE_C3_STANDARD_4 - default "c3-standard-8" if TERRAFORM_GCE_MACHINE_C3_STANDARD_8 - default "c3-standard-22" if TERRAFORM_GCE_MACHINE_C3_STANDARD_22 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.c3d-standard b/terraform/gce/kconfigs/machines/Kconfig.c3d-standard deleted file mode 100644 index 4af821e5a..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.c3d-standard +++ /dev/null @@ -1,46 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 - help - C3D VMs are powered by the 4th-gen AMD EPYC (Genoa) - processor. C3D uses Titanium, enabling higher levels - of networking performance, isolation and security. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 - bool "c3d-standard-4" - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_8 - bool "c3d-standard-8" - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_16 - bool "c3d-standard-16" - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_30 - bool "c3d-standard-30" - help - 30 vCPUs (15 cores) and 120GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c3d-standard-4" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 - default "c3d-standard-8" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_8 - default "c3d-standard-16" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_16 - default "c3d-standard-30" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_30 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.c4-standard b/terraform/gce/kconfigs/machines/Kconfig.c4-standard deleted file mode 100644 index 3ec7f4ec1..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.c4-standard +++ /dev/null @@ -1,58 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C4_STANDARD_4 - help - C4 VMs are powered by 6th generation (code-named Granite - Rapids) or 5th generation (code-named Emerald Rapids) - Intel Xeon Scalable processors and Titanium. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_2 - bool "c4-standard-2" - help - 2 vCPUs (1 core) and 7GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_4 - bool "c4-standard-4" - help - 4 vCPUs (2 core) and 15GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_8 - bool "c4-standard-8" - help - 8 vCPUs (4 cores) and 30GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_16 - bool "c4-standard-16" - help - 16 vCPUs (8 cores) and 60GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_24 - bool "c4-standard-24" - help - 24 vCPUs (12 cores) and 90GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_32 - bool "c4-standard-32" - help - 32 vCPUs (16 cores) and 120 of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c4-standard-2" if TERRAFORM_GCE_MACHINE_C4_STANDARD_2 - default "c4-standard-4" if TERRAFORM_GCE_MACHINE_C4_STANDARD_4 - default "c4-standard-8" if TERRAFORM_GCE_MACHINE_C4_STANDARD_8 - default "c4-standard-16" if TERRAFORM_GCE_MACHINE_C4_STANDARD_16 - default "c4-standard-24" if TERRAFORM_GCE_MACHINE_C4_STANDARD_24 - default "c4-standard-32" if TERRAFORM_GCE_MACHINE_C4_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.c4a-standard b/terraform/gce/kconfigs/machines/Kconfig.c4a-standard deleted file mode 100644 index 3a486fe4a..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.c4a-standard +++ /dev/null @@ -1,57 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 - help - C4A VMs are powered by Google's first Arm-based Axion™ - processor, DDR5 memory, and local Titanium SSDs. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 - bool "c4a-standard-1" - help - 1 vCPU and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 - bool "c4a-standard-2" - help - 2 vCPUs and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 - bool "c4a-standard-4" - help - 4 vCPUs and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 - bool "c4a-standard-8" - help - 8 vCPUs and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 - bool "c4a-standard-16" - help - 16 vCPUs and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 - bool "c4a-standard-32" - help - 32 vCPUs and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c4a-standard-1" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 - default "c4a-standard-2" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 - default "c4a-standard-4" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 - default "c4a-standard-8" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 - default "c4a-standard-16" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 - default "c4a-standard-32" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.c4d-standard b/terraform/gce/kconfigs/machines/Kconfig.c4d-standard deleted file mode 100644 index 6d7b4bb96..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.c4d-standard +++ /dev/null @@ -1,51 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 - help - C4D VMs are powered by the fifth generation AMD EPYC Turin - processor and Titanium. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_2 - bool "c4d-standard-2" - help - 2 vCPUs (1 core) and 7GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 - bool "c4d-standard-4" - help - 4 vCPUs (2 core) and 15GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_8 - bool "c4d-standard-8" - help - 8 vCPUs (4 cores) and 31GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_16 - bool "c4d-standard-16" - help - 16 vCPUs (8 cores) and 62GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_24 - bool "c4d-standard-24" - help - 32 vCPUs (16 cores) and 124GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c4d-standard-2" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_2 - default "c4d-standard-4" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 - default "c4d-standard-8" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_8 - default "c4d-standard-16" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_16 - default "c4d-standard-32" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.e2-highcpu b/terraform/gce/kconfigs/machines/Kconfig.e2-highcpu deleted file mode 100644 index eb401451b..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.e2-highcpu +++ /dev/null @@ -1,58 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 - help - The E2 machine series offers both Intel and AMD EPYC - processors, selected for you at the time of VM creation. - Machine types in this series are available in all regions - and zones and support a virtio memory balloon device. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 - bool "e2-highcpu-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 2GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 - bool "e2-highcpu-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 - bool "e2-highcpu-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 - bool "e2-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 - bool "e2-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 32GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "e2-highcpu-2" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 - default "e2-highcpu-4" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 - default "e2-highcpu-8" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 - default "e2-highcpu-16" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 - default "e2-highcpu-32" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.e2-standard b/terraform/gce/kconfigs/machines/Kconfig.e2-standard deleted file mode 100644 index 26180f841..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.e2-standard +++ /dev/null @@ -1,58 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_E2_STANDARD_8 - help - The E2 machine series offers both Intel and AMD EPYC - processors, selected for you at the time of VM creation. - Machine types in this series are available in all regions - and zones and support a virtio memory balloon device. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_2 - bool "e2-standard-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_4 - bool "e2-standard-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_8 - bool "e2-standard-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_16 - bool "e2-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_32 - bool "e2-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "e2-standard-2" if TERRAFORM_GCE_MACHINE_E2_STANDARD_2 - default "e2-standard-4" if TERRAFORM_GCE_MACHINE_E2_STANDARD_4 - default "e2-standard-8" if TERRAFORM_GCE_MACHINE_E2_STANDARD_8 - default "e2-standard-16" if TERRAFORM_GCE_MACHINE_E2_STANDARD_16 - default "e2-standard-32" if TERRAFORM_GCE_MACHINE_E2_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.n1-highcpu b/terraform/gce/kconfigs/machines/Kconfig.n1-highcpu deleted file mode 100644 index 7684b2961..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n1-highcpu +++ /dev/null @@ -1,55 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 - help - The N1 machine series is Compute Engine's first generation - general-purpose machine series available on Intel Skylake, - Broadwell, Haswell, Sandy Bridge, and Ivy Bridge CPU - platforms. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 - bool "n1-highcpu-2" - help - 2 vCPUs (1 core) and 1.8GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 - bool "n1-highcpu-4" - help - 4 vCPUs (2 cores) and 3.6GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 - bool "n1-highcpu-8" - help - 8 vCPUs (4 cores) and 7.2GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 - bool "n1-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 14.4GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 - bool "n1-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 28.8GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n1-highcpu-2" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 - default "n1-highcpu-4" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 - default "n1-highcpu-8" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 - default "n1-highcpu-16" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 - default "n1-highcpu-32" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.n1-standard b/terraform/gce/kconfigs/machines/Kconfig.n1-standard deleted file mode 100644 index 7201231c7..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n1-standard +++ /dev/null @@ -1,61 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N1_STANDARD_8 - help - The N1 machine series is Compute Engine's first generation - general-purpose machine series available on Intel Skylake, - Broadwell, Haswell, Sandy Bridge, and Ivy Bridge CPU - platforms. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_1 - bool "n1-standard-1" - help - 1 vCPU and 3.75GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_2 - bool "n1-standard-2" - help - 2 vCPUs (1 core) and 7.5GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_4 - bool "n1-standard-4" - help - 4 vCPUs (2 cores) and 15GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_8 - bool "n1-standard-8" - help - 8 vCPUs (4 cores) and 30GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_16 - bool "n1-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 60GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_32 - bool "n1-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 120GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n1-standard-1" if TERRAFORM_GCE_MACHINE_N1_STANDARD_1 - default "n1-standard-2" if TERRAFORM_GCE_MACHINE_N1_STANDARD_2 - default "n1-standard-4" if TERRAFORM_GCE_MACHINE_N1_STANDARD_4 - default "n1-standard-8" if TERRAFORM_GCE_MACHINE_N1_STANDARD_8 - default "n1-standard-16" if TERRAFORM_GCE_MACHINE_N1_STANDARD_16 - default "n1-standard-32" if TERRAFORM_GCE_MACHINE_N1_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.n2-highcpu b/terraform/gce/kconfigs/machines/Kconfig.n2-highcpu deleted file mode 100644 index 83823753d..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n2-highcpu +++ /dev/null @@ -1,56 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 - help - The N2 machine series can run on either Intel Cascade Lake - (on smaller configurations) or Intel Ice Lake. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 - bool "n2-highcpu-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 2GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 - bool "n2-highcpu-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 - bool "n2-highcpu-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 - bool "n2-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 - bool "n2-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 32GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2-highcpu-2" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 - default "n2-highcpu-4" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 - default "n2-highcpu-8" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 - default "n2-highcpu-16" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 - default "n2-highcpu-32" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.n2-standard b/terraform/gce/kconfigs/machines/Kconfig.n2-standard deleted file mode 100644 index a485a754a..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n2-standard +++ /dev/null @@ -1,56 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2_STANDARD_8 - help - The N2 machine series can run on either Intel Cascade Lake - (on smaller configurations) or Intel Ice Lake. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_2 - bool "n2-standard-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_4 - bool "n2-standard-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_8 - bool "n2-standard-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_16 - bool "n2-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_32 - bool "n2-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2-standard-2" if TERRAFORM_GCE_MACHINE_N2_STANDARD_2 - default "n2-standard-4" if TERRAFORM_GCE_MACHINE_N2_STANDARD_4 - default "n2-standard-8" if TERRAFORM_GCE_MACHINE_N2_STANDARD_8 - default "n2-standard-16" if TERRAFORM_GCE_MACHINE_N2_STANDARD_16 - default "n2-standard-32" if TERRAFORM_GCE_MACHINE_N2_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.n2d-highcpu b/terraform/gce/kconfigs/machines/Kconfig.n2d-highcpu deleted file mode 100644 index e3cf9c6e5..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n2d-highcpu +++ /dev/null @@ -1,57 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 - help - The N2D machine series can run on either AMD EPYC Milan or - AMD EPYC Rome processors. The third generation AMD EPYC - Milan processor is available only in specific regions and zones. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 - bool "n2d-highcpu-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPU (1 core) and 2GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 - bool "n2d-highcpu-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 - bool "n2d-highcpu-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 - bool "n2d-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 - bool "n2d-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 32GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2d-highcpu-2" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 - default "n2d-highcpu-4" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 - default "n2d-highcpu-8" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 - default "n2d-highcpu-16" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 - default "n2d-highcpu-32" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.n2d-standard b/terraform/gce/kconfigs/machines/Kconfig.n2d-standard deleted file mode 100644 index 4f86e0b7d..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n2d-standard +++ /dev/null @@ -1,57 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 - help - The N2D machine series can run on either AMD EPYC Milan or - AMD EPYC Rome processors. The third generation AMD EPYC - Milan processor is available only in specific regions and zones. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 - bool "n2d-standard-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 - bool "n2d-standard-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 - bool "n2d-standard-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 - bool "n2d-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 - bool "n2d-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2d-standard-2" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 - default "n2d-standard-4" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 - default "n2d-standard-8" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 - default "n2d-standard-16" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 - default "n2d-standard-32" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD diff --git a/terraform/gce/kconfigs/machines/Kconfig.n4-highcpu b/terraform/gce/kconfigs/machines/Kconfig.n4-highcpu deleted file mode 100644 index 880a386ea..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n4-highcpu +++ /dev/null @@ -1,51 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 - help - N4 VMs are powered by the 5th generation Intel Xeon Scalable - processors (code-named Emerald Rapids) and Titanium. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_2 - bool "n4-highcpu-2" - help - 2 vCPUs (1 core) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 - bool "n4-highcpu-4" - help - 4 vCPUs (2 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_8 - bool "n4-highcpu-8" - help - 8 vCPUs (4 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_16 - bool "n4-highcpu-16" - help - 16 vCPUs (8 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_32 - bool "n4-highcpu-32" - help - 32 vCPUs (16 cores) and 64GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n4-highcpu-2" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_2 - default "n4-highcpu-4" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 - default "n4-highcpu-8" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_8 - default "n4-highcpu-16" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_16 - default "n4-highcpu-32" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU diff --git a/terraform/gce/kconfigs/machines/Kconfig.n4-standard b/terraform/gce/kconfigs/machines/Kconfig.n4-standard deleted file mode 100644 index 807f8638e..000000000 --- a/terraform/gce/kconfigs/machines/Kconfig.n4-standard +++ /dev/null @@ -1,51 +0,0 @@ -if TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_N4_STANDARD_4 - help - N4 VMs are powered by the 5th generation Intel Xeon Scalable - processors (code-named Emerald Rapids) and Titanium. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_2 - bool "n4-standard-2" - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_4 - bool "n4-standard-4" - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_8 - bool "n4-standard-8" - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_16 - bool "n4-standard-16" - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_32 - bool "n4-standard-32" - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n4-standard-2" if TERRAFORM_GCE_MACHINE_N4_STANDARD_2 - default "n4-standard-4" if TERRAFORM_GCE_MACHINE_N4_STANDARD_4 - default "n4-standard-8" if TERRAFORM_GCE_MACHINE_N4_STANDARD_8 - default "n4-standard-16" if TERRAFORM_GCE_MACHINE_N4_STANDARD_16 - default "n4-standard-32" if TERRAFORM_GCE_MACHINE_N4_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD From 1417d98bffec39c3fd7a244d5a0580c90f547931 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2025 17:20:15 -0500 Subject: [PATCH 4/8] terraform/gce: Remove the kconfigs/images subdirectory Instead of sourcing files in a subdirectory, move the content of those files right into Kconfig.image. This will make it easier to examine the differences between the current menu content and the dynamically-generated content. The consolidation is bug-for-bug compatible with the original files, including missing default selections in some choice blocks. Signed-off-by: Chuck Lever --- terraform/gce/kconfigs/Kconfig.image | 354 +++++++++++++++++- terraform/gce/kconfigs/images/Kconfig.centos | 49 --- terraform/gce/kconfigs/images/Kconfig.debian | 53 --- .../gce/kconfigs/images/Kconfig.opensuse | 35 -- terraform/gce/kconfigs/images/Kconfig.oracle | 34 -- terraform/gce/kconfigs/images/Kconfig.rhel | 66 ---- terraform/gce/kconfigs/images/Kconfig.rocky | 53 --- terraform/gce/kconfigs/images/Kconfig.sles | 51 --- 8 files changed, 347 insertions(+), 348 deletions(-) delete mode 100644 terraform/gce/kconfigs/images/Kconfig.centos delete mode 100644 terraform/gce/kconfigs/images/Kconfig.debian delete mode 100644 terraform/gce/kconfigs/images/Kconfig.opensuse delete mode 100644 terraform/gce/kconfigs/images/Kconfig.oracle delete mode 100644 terraform/gce/kconfigs/images/Kconfig.rhel delete mode 100644 terraform/gce/kconfigs/images/Kconfig.rocky delete mode 100644 terraform/gce/kconfigs/images/Kconfig.sles diff --git a/terraform/gce/kconfigs/Kconfig.image b/terraform/gce/kconfigs/Kconfig.image index 3477600ca..a4487a045 100644 --- a/terraform/gce/kconfigs/Kconfig.image +++ b/terraform/gce/kconfigs/Kconfig.image @@ -28,10 +28,350 @@ config TERRAFORM_GCE_DISTRO_SLES endchoice -source "terraform/gce/kconfigs/images/Kconfig.centos" -source "terraform/gce/kconfigs/images/Kconfig.debian" -source "terraform/gce/kconfigs/images/Kconfig.oracle" -source "terraform/gce/kconfigs/images/Kconfig.opensuse" -source "terraform/gce/kconfigs/images/Kconfig.rhel" -source "terraform/gce/kconfigs/images/Kconfig.rocky" -source "terraform/gce/kconfigs/images/Kconfig.sles" +if TERRAFORM_GCE_DISTRO_CENTOS + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "centos-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 + bool "CentOS Stream 9 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "centos-stream-9" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 + bool "CentOS Stream 9 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "centos-stream-9-arm64" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_CENTOS + +if TERRAFORM_GCE_DISTRO_DEBIAN + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "debian-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 + +config TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 + bool "Debian-11 Bullseye (x86)" + +config TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 + bool "Debian-12 Bookworm (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "debian-11" if TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 + default "debian-12" if TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 + +config TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 + bool "Debian-12 Bookworm (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "debian-12-arm64" if TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_DEBIAN + +if TERRAFORM_GCE_DISTRO_OPENSUSE + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "opensuse-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 + +config TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 + bool "OpenLeap 15.5 (x86)" + +config TERRAFORM_GCE_IMAGE_OPENLEAP_15_6_X86_64 + bool "OpenLeap 15.6 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "opensuse-leap-15-5" if TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 + default "opensuse-leap-15-6" if TERRAFORM_GCE_IMAGE_OPENLEAP_15_6_X86_64 + +endif # TARGET_ARCH_X86_64 + +endif # TERRAFORM_GCE_DISTRO_OPENSUSE + +if TERRAFORM_GCE_DISTRO_OL + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "oracle-linux-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + +config TERRAFORM_GCE_IMAGE_OL_8_X86_64 + bool "Oracle Linux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_OL_9_X86_64 + bool "Oracle Linux 9 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "oracle-linux-8" if TERRAFORM_GCE_IMAGE_OL_8_X86_64 + default "oracle-linux-9" if TERRAFORM_GCE_IMAGE_OL_9_X86_64 + +endif # TARGET_ARCH_X86_64 + +endif # TERRAFORM_GCE_DISTRO_OL + +if TERRAFORM_GCE_DISTRO_RHEL + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "rhel-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +choice + prompt "License type" + default TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL + +config TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL + bool "Pay as you go" + +config TERRAFORM_GCE_LICENSE_TYPE_BYOS_RHEL + bool "Bring your own subscription or license" + +endchoice + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + +config TERRAFORM_GCE_IMAGE_RHEL_8_X86_64_PAYGO + depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL + bool "Red Hat Enterprise Linux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_RHEL_9_X86_64_PAYGO + depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL + bool "Red Hat Enterprise Linux 9 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rhel-8" if TERRAFORM_GCE_IMAGE_RHEL_8_X86_64_PAYGO + default "rhel-9" if TERRAFORM_GCE_IMAGE_RHEL_9_X86_64_PAYGO + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + +config TERRAFORM_GCE_IMAGE_RHEL_9_ARM64_PAYGO + depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL + bool "Red Hat Enterprise Linux 9 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rhel-9-arm64" if TERRAFORM_GCE_IMAGE_RHEL_9_ARM64_PAYGO + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_RHEL + +if TERRAFORM_GCE_DISTRO_ROCKY + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "rocky-linux-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 + +config TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 + bool "Rocky Linux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 + bool "Rocky Linux 9 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rocky-linux-8" if TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 + default "rocky-linux-9" if TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 + +config TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 + bool "Rocky Linux 9 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rocky-linux-9-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_ROCKY + +if TERRAFORM_GCE_DISTRO_SLES + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "suse-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + +config TERRAFORM_GCE_IMAGE_SLES_12_X86_64 + bool "SUSE Linux Enterprise Server 12 (x86)" + +config TERRAFORM_GCE_IMAGE_SLES_15_X86_64 + bool "SUSE Linux Enterprise Server 15 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "sles-12" if TERRAFORM_GCE_IMAGE_SLES_12_X86_64 + default "sles-15" if TERRAFORM_GCE_IMAGE_SLES_15_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + +config TERRAFORM_GCE_IMAGE_SLES_15_ARM64 + bool "SUSE Linux Enterprise Server 15 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "sles-15-arm64" if TERRAFORM_GCE_IMAGE_SLES_15_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_SLES diff --git a/terraform/gce/kconfigs/images/Kconfig.centos b/terraform/gce/kconfigs/images/Kconfig.centos deleted file mode 100644 index c5cdaeb82..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.centos +++ /dev/null @@ -1,49 +0,0 @@ -if TERRAFORM_GCE_DISTRO_CENTOS - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "centos-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 - -config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 - bool "CentOS Stream 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "centos-stream-9" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 - -config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 - bool "CentOS Stream 9 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "centos-stream-9-arm64" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_CENTOS diff --git a/terraform/gce/kconfigs/images/Kconfig.debian b/terraform/gce/kconfigs/images/Kconfig.debian deleted file mode 100644 index 0aeb0fe6c..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.debian +++ /dev/null @@ -1,53 +0,0 @@ -if TERRAFORM_GCE_DISTRO_DEBIAN - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "debian-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 10 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 - -config TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 - bool "Debian-11 Bullseye (x86)" - -config TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 - bool "Debian-12 Bookworm (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "debian-11" if TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 - default "debian-12" if TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 - -config TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 - bool "Debian-12 Bookworm (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "debian-12-arm64" if TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_DEBIAN diff --git a/terraform/gce/kconfigs/images/Kconfig.opensuse b/terraform/gce/kconfigs/images/Kconfig.opensuse deleted file mode 100644 index ae8b3c461..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.opensuse +++ /dev/null @@ -1,35 +0,0 @@ -if TERRAFORM_GCE_DISTRO_OPENSUSE - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "opensuse-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 10 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 - -config TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 - bool "OpenLeap 15.5 (x86)" - -config TERRAFORM_GCE_IMAGE_OPENLEAP_15_6_X86_64 - bool "OpenLeap 15.6 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "opensuse-leap-15-5" if TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 - default "opensuse-leap-15-6" if TERRAFORM_GCE_IMAGE_OPENLEAP_15_6_X86_64 - -endif # TARGET_ARCH_X86_64 - -endif # TERRAFORM_GCE_DISTRO_OPENSUSE diff --git a/terraform/gce/kconfigs/images/Kconfig.oracle b/terraform/gce/kconfigs/images/Kconfig.oracle deleted file mode 100644 index 135e8707d..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.oracle +++ /dev/null @@ -1,34 +0,0 @@ -if TERRAFORM_GCE_DISTRO_OL - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "oracle-linux-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_OL_8_X86_64 - bool "Oracle Linux 8 (x86)" - -config TERRAFORM_GCE_IMAGE_OL_9_X86_64 - bool "Oracle Linux 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "oracle-linux-8" if TERRAFORM_GCE_IMAGE_OL_8_X86_64 - default "oracle-linux-9" if TERRAFORM_GCE_IMAGE_OL_9_X86_64 - -endif # TARGET_ARCH_X86_64 - -endif # TERRAFORM_GCE_DISTRO_OL diff --git a/terraform/gce/kconfigs/images/Kconfig.rhel b/terraform/gce/kconfigs/images/Kconfig.rhel deleted file mode 100644 index 64a5df97e..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.rhel +++ /dev/null @@ -1,66 +0,0 @@ -if TERRAFORM_GCE_DISTRO_RHEL - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "rhel-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -choice - prompt "License type" - default TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - -config TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Pay as you go" - -config TERRAFORM_GCE_LICENSE_TYPE_BYOS_RHEL - bool "Bring your own subscription or license" - -endchoice - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_RHEL_8_X86_64_PAYGO - depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Red Hat Enterprise Linux 8 (x86)" - -config TERRAFORM_GCE_IMAGE_RHEL_9_X86_64_PAYGO - depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Red Hat Enterprise Linux 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rhel-8" if TERRAFORM_GCE_IMAGE_RHEL_8_X86_64_PAYGO - default "rhel-9" if TERRAFORM_GCE_IMAGE_RHEL_9_X86_64_PAYGO - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_RHEL_9_ARM64_PAYGO - depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Red Hat Enterprise Linux 9 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rhel-9-arm64" if TERRAFORM_GCE_IMAGE_RHEL_9_ARM64_PAYGO - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_RHEL diff --git a/terraform/gce/kconfigs/images/Kconfig.rocky b/terraform/gce/kconfigs/images/Kconfig.rocky deleted file mode 100644 index e4694e21c..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.rocky +++ /dev/null @@ -1,53 +0,0 @@ -if TERRAFORM_GCE_DISTRO_ROCKY - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "rocky-linux-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 - -config TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 - bool "Rocky Linux 8 (x86)" - -config TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 - bool "Rocky Linux 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rocky-linux-8" if TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 - default "rocky-linux-9" if TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 - -config TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 - bool "Rocky Linux 9 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rocky-linux-9-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_ROCKY diff --git a/terraform/gce/kconfigs/images/Kconfig.sles b/terraform/gce/kconfigs/images/Kconfig.sles deleted file mode 100644 index fef6adf51..000000000 --- a/terraform/gce/kconfigs/images/Kconfig.sles +++ /dev/null @@ -1,51 +0,0 @@ -if TERRAFORM_GCE_DISTRO_SLES - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "suse-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 10 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_SLES_12_X86_64 - bool "SUSE Linux Enterprise Server 12 (x86)" - -config TERRAFORM_GCE_IMAGE_SLES_15_X86_64 - bool "SUSE Linux Enterprise Server 15 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "sles-12" if TERRAFORM_GCE_IMAGE_SLES_12_X86_64 - default "sles-15" if TERRAFORM_GCE_IMAGE_SLES_15_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_SLES_15_ARM64 - bool "SUSE Linux Enterprise Server 15 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "sles-15-arm64" if TERRAFORM_GCE_IMAGE_SLES_15_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_SLES From 3cc28cca62cce29ad741b6612283d4b8d1a9c8c7 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Wed, 3 Dec 2025 22:02:48 -0500 Subject: [PATCH 5/8] terraform/gce: Generate Kconfig.location dynamically This adds a Python script that queries the Google Cloud REST API to retrieve available regions and zones, and then generates the GCE Kconfig.location file dynamically. This ensures the region list is always up-to-date and includes only regions accessible to the user's project. The implementation follows the same pattern as AWS and OCI. It provides dynamic region discovery via the Google Cloud REST API with friendly display names for each region. Inaccessible regions are automatically filtered, and the script supports both command-line querying and Kconfig file generation. Generated-by: Claude AI Signed-off-by: Chuck Lever --- .gitignore | 2 + terraform/gce/scripts/gce_common.py | 359 +++++++++++ terraform/gce/scripts/gen_kconfig_location | 565 ++++++++++++++++++ .../gce/scripts/region_friendly_names.yml | 89 +++ terraform/gce/scripts/regions.j2 | 29 + terraform/gce/scripts/zone.j2 | 23 + 6 files changed, 1067 insertions(+) create mode 100644 terraform/gce/scripts/gce_common.py create mode 100755 terraform/gce/scripts/gen_kconfig_location create mode 100644 terraform/gce/scripts/region_friendly_names.yml create mode 100644 terraform/gce/scripts/regions.j2 create mode 100644 terraform/gce/scripts/zone.j2 diff --git a/.gitignore b/.gitignore index 034ca44fc..e1f803551 100644 --- a/.gitignore +++ b/.gitignore @@ -132,6 +132,8 @@ terraform/azure/kconfigs/Kconfig.location.generated terraform/azure/kconfigs/Kconfig.size.generated terraform/azure/scripts/__pycache__/ +terraform/gce/scripts/__pycache__/ + terraform/oci/kconfigs/Kconfig.image.generated terraform/oci/kconfigs/Kconfig.location.generated terraform/oci/kconfigs/Kconfig.shape.generated diff --git a/terraform/gce/scripts/gce_common.py b/terraform/gce/scripts/gce_common.py new file mode 100644 index 000000000..c6cf744ca --- /dev/null +++ b/terraform/gce/scripts/gce_common.py @@ -0,0 +1,359 @@ +#!/usr/bin/env python3 +# ex: set filetype=python: + +""" +Common utilities for GCE Kconfig generation scripts. + +This module provides shared functionality used by gen_kconfig_location +and other gen_kconfig_* scripts to avoid code duplication. + +API Approach: + Unlike the AWS, Azure, and OCI scripts which use their respective + provider SDKs (boto3, azure-mgmt-*, oci), this module uses the GCE + REST API directly with google-auth and requests. + + This design choice was made because the google-cloud-compute SDK + is not widely packaged in Linux distributions: + + - Fedora: Not packaged + - Debian/Ubuntu: Not packaged (python3-google-compute-engine is + a different package for running inside GCE VMs) + - openSUSE/SUSE: Available as python-google-cloud-compute + + In contrast, google-auth and requests are available as distribution + packages across all major Linux distributions, making this approach + work out-of-the-box without requiring pip. + + The REST API provides the same functionality and is well-documented: + https://cloud.google.com/compute/docs/reference/rest/v1 +""" + +from __future__ import annotations + +import os +import sys +from configparser import ConfigParser +from pathlib import Path +from typing import Any, Optional + +import yaml +from jinja2 import Environment, FileSystemLoader + +import requests +import google.auth +import google.auth.exceptions +import google.auth.transport.requests + + +class GceNotConfiguredError(Exception): + """Raised when GCE credentials are not available.""" + + +# GCE Compute API base URL +GCE_COMPUTE_API = "https://compute.googleapis.com/compute/v1" + +# Timeout in seconds for GCE API requests to prevent indefinite hangs +GCE_API_TIMEOUT = 30 + + +def get_authenticated_session() -> ( + tuple[google.auth.transport.requests.AuthorizedSession, str] +): + """ + Create an authenticated requests session for GCE API calls. + + Returns an AuthorizedSession that automatically handles OAuth2 token + refresh. This allows long-running callers to make API requests without + worrying about token expiration. + + Returns: + tuple: (session, project_id) - AuthorizedSession and project ID + + Raises: + ValueError: If project ID cannot be determined + google.auth.exceptions.DefaultCredentialsError: If authentication fails + """ + credentials, project = google.auth.default( + scopes=["https://www.googleapis.com/auth/compute.readonly"] + ) + + if not project: + # Try environment variables + project = os.environ.get("GOOGLE_CLOUD_PROJECT") or os.environ.get( + "GCLOUD_PROJECT" + ) + + if not project: + raise ValueError( + "Could not determine GCE project. Set GOOGLE_CLOUD_PROJECT " + "environment variable or configure gcloud default project." + ) + + # Create authenticated session with automatic token refresh + session = google.auth.transport.requests.AuthorizedSession(credentials) + + return session, project + + +def get_default_project() -> Optional[str]: + """ + Get the default GCE project from gcloud configuration. + + Returns: + str: Default project ID, or None if not found. + """ + try: + _, project = google.auth.default() + if project: + return project + except google.auth.exceptions.DefaultCredentialsError: + pass + + # Try environment variable + if "GOOGLE_CLOUD_PROJECT" in os.environ: + return os.environ["GOOGLE_CLOUD_PROJECT"] + + if "GCLOUD_PROJECT" in os.environ: + return os.environ["GCLOUD_PROJECT"] + + return None + + +def _get_gcloud_config_value(section: str, key: str) -> Optional[str]: + """ + Read a value from the gcloud properties file. + + Args: + section: Config section name (e.g., 'compute') + key: Config key name (e.g., 'region', 'zone') + + Returns: + The config value if found, None otherwise. + """ + config_path = os.path.expanduser("~/.config/gcloud/properties") + if not os.path.exists(config_path): + return None + + try: + config = ConfigParser() + config.read(config_path) + if section in config and key in config[section]: + return config[section][key] + except Exception as e: + print(f"Warning: Error reading gcloud config: {e}", file=sys.stderr) + + return None + + +def get_default_region() -> str: + """ + Get the default GCE region from gcloud configuration. + + Returns: + str: Default region, or 'us-west2' if no default is found. + """ + if "CLOUDSDK_COMPUTE_REGION" in os.environ: + return os.environ["CLOUDSDK_COMPUTE_REGION"] + + value = _get_gcloud_config_value("compute", "region") + if value: + return value + + return "us-west2" + + +def get_default_zone() -> str: + """ + Get the default GCE zone from gcloud configuration. + + Returns: + str: Default zone, or 'us-west2-a' if no default is found. + """ + if "CLOUDSDK_COMPUTE_ZONE" in os.environ: + return os.environ["CLOUDSDK_COMPUTE_ZONE"] + + value = _get_gcloud_config_value("compute", "zone") + if value: + return value + + return "us-west2-a" + + +def get_jinja2_environment(template_path: Optional[str] = None) -> Environment: + """ + Create a standardized Jinja2 environment for template rendering. + + Args: + template_path (str): Path to template directory. If None, uses caller's directory. + + Returns: + Environment: Configured Jinja2 Environment object + """ + if template_path is None: + template_path = Path(__file__).parent + + return Environment( + loader=FileSystemLoader(template_path), + trim_blocks=True, + lstrip_blocks=True, + extensions=["jinja2.ext.loopcontrols"], + ) + + +def load_yaml_config( + filename: str, quiet: bool = False, default: Optional[Any] = None +) -> Any: + """ + Load a YAML configuration file with consistent error handling. + + This function provides standardized YAML loading used across all + gen_kconfig_* scripts for loading configuration files like + region_friendly_names.yml. + + Args: + filename (str): Name of YAML file (not full path - will be looked up + in script directory) + quiet (bool): Suppress warning messages to stderr + default: Default value to return on error (default: empty dict) + + Returns: + Data loaded from YAML file, or default value on error + """ + if default is None: + default = {} + + yaml_path = Path(__file__).parent / filename + + try: + with open(yaml_path, "r") as f: + data = yaml.safe_load(f) + return data if data else default + except FileNotFoundError: + if not quiet: + print(f"Warning: {yaml_path} not found. Using defaults.", file=sys.stderr) + return default + except yaml.YAMLError as e: + if not quiet: + print( + f"Warning: Error parsing {yaml_path}: {e}. Using defaults.", + file=sys.stderr, + ) + return default + + +def get_region_kconfig_name(region_name: str) -> str: + """ + Convert GCE region name to Kconfig region constant name. + + Args: + region_name (str): GCE region name (e.g., 'us-west2', 'asia-south1') + + Returns: + str: Kconfig constant name (e.g., 'US_WEST2', 'ASIA_SOUTH1') + """ + return region_name.upper().replace("-", "_") + + +def get_zone_kconfig_name(zone_name: str) -> str: + """ + Convert GCE zone name to Kconfig zone constant name. + + Args: + zone_name (str): GCE zone name (e.g., 'us-west2-a', 'asia-south1-b') + + Returns: + str: Kconfig constant name (e.g., 'US_WEST2_A', 'ASIA_SOUTH1_B') + """ + return zone_name.upper().replace("-", "_") + + +def list_regions(session: requests.Session, project: str) -> list[dict]: + """ + List all GCE regions using the REST API. + + Args: + session: Authenticated requests session + project: GCE project ID + + Returns: + list: List of region dictionaries from the API + """ + url = f"{GCE_COMPUTE_API}/projects/{project}/regions" + # Request only needed fields to reduce response size and latency + params = {"fields": "items(name,status,zones)"} + response = session.get(url, params=params, timeout=GCE_API_TIMEOUT) + response.raise_for_status() + + data = response.json() + return data.get("items", []) + + +def list_zones(session: requests.Session, project: str) -> list[dict]: + """ + List all GCE zones using the REST API. + + Args: + session: Authenticated requests session + project: GCE project ID + + Returns: + list: List of zone dictionaries from the API + """ + url = f"{GCE_COMPUTE_API}/projects/{project}/zones" + # Request only needed fields to reduce response size and latency + params = {"fields": "items(name,status)"} + response = session.get(url, params=params, timeout=GCE_API_TIMEOUT) + response.raise_for_status() + + data = response.json() + return data.get("items", []) + + +def exit_on_empty_result(result, context: str, quiet: bool = False) -> None: + """ + Exit with error if result is empty or None. + + This consolidates the common pattern of checking if an API query + returned results and exiting with appropriate error messaging if not. + + Args: + result: Result from API query (list, dict, or other iterable) + context (str): Description of what operation failed + quiet (bool): Suppress error messages + """ + if not result: + if not quiet: + print( + f"Error: Cannot perform {context}. Check GCE authentication status.", + file=sys.stderr, + ) + print( + "Run 'gcloud auth application-default login' to authenticate.", + file=sys.stderr, + ) + sys.exit(1) + + +def require_gce_credentials(): + """ + Require GCE credentials, raising an exception if not configured. + + This function should be called early in main() to validate GCE + credentials. If GCE is not configured, it raises GceNotConfiguredError + to let the caller decide how to handle it. + + This centralizes the handling of missing GCE credentials and avoids + TOCTOU race conditions from manual file existence checks. + + Returns: + tuple: (session, project_id) if credentials are valid + + Raises: + GceNotConfiguredError: If GCE credentials are not found + """ + try: + return get_authenticated_session() + except ValueError as e: + raise GceNotConfiguredError(str(e)) from e + except google.auth.exceptions.DefaultCredentialsError as e: + raise GceNotConfiguredError("GCE credentials not found") from e diff --git a/terraform/gce/scripts/gen_kconfig_location b/terraform/gce/scripts/gen_kconfig_location new file mode 100755 index 000000000..a687b0813 --- /dev/null +++ b/terraform/gce/scripts/gen_kconfig_location @@ -0,0 +1,565 @@ +#!/usr/bin/env python3 +# ex: set filetype=python: + +""" +Retrieve region and zone information from GCE. Use it to construct +the "locations" Kconfig menu. + +This script queries the GCE API to dynamically generate a Kconfig file +containing all available GCE regions and their zones. It uses the REST +API directly with google-auth and requests rather than the +google-cloud-compute SDK. See gce_common.py for details on why this +approach was chosen. + +Region Friendly Names: + Region friendly names (e.g., "Los Angeles, California, USA") are maintained + in the region_friendly_names.yml file in the same directory as this script. + This makes it easier to update the friendly names when Google adds new + regions or when you want to customize the display names. + + To update region friendly names: + 1. Edit terraform/gce/scripts/region_friendly_names.yml + 2. Add or modify entries following the existing format + 3. Run this script to regenerate Kconfig.location + + The YAML file contains detailed instructions for how to find and add + new region information. If a region is not found in the YAML file, + the script will auto-generate a friendly name from the region identifier. + +Usage: + # Generate complete Kconfig.location file + ./gen_kconfig_location > ../kconfigs/Kconfig.location + + # List all available regions + ./gen_kconfig_location --regions + + # Get details for a specific region + ./gen_kconfig_location us-west2 +""" + +from __future__ import annotations + +import sys +import argparse +from concurrent.futures import ThreadPoolExecutor +from typing import Any, Optional + +from google.auth.transport.requests import AuthorizedSession + +from gce_common import ( + GceNotConfiguredError, + get_default_region, + get_jinja2_environment, + get_region_kconfig_name, + get_zone_kconfig_name, + load_yaml_config, + list_regions, + list_zones, + exit_on_empty_result, + require_gce_credentials, +) + + +def load_region_friendly_names() -> dict[str, str]: + """ + Load region friendly names from the YAML configuration file. + + The friendly names are maintained in region_friendly_names.yml to make + it easier to update when Google adds new regions. The YAML file contains + the canonical mapping from GCE region identifiers to human-readable + display names. + + To update the friendly names: + 1. Edit terraform/gce/scripts/region_friendly_names.yml + 2. Add or modify entries following the existing format + 3. Regenerate Kconfig.location by running this script + + See region_friendly_names.yml for detailed update instructions. + + Returns: + dict: Dictionary mapping region names to friendly display names + """ + return load_yaml_config("region_friendly_names.yml") + + +def get_region_friendly_name( + region_name: str, friendly_names: Optional[dict[str, str]] = None +) -> str: + """ + Get a friendly display name for a region. + + Region friendly names are loaded from region_friendly_names.yml. + If a region is not found in the YAML file, an auto-generated name + is returned. + + The YAML file can be updated to add new regions or customize names. + See load_region_friendly_names() for update instructions. + + Args: + region_name (str): GCE region name (e.g., 'us-west2') + friendly_names (dict): Optional pre-loaded friendly names dict. + If None, names will be loaded from YAML. + + Returns: + str: Friendly name (e.g., 'Los Angeles, California, USA') + """ + # Load friendly names from YAML if not provided + if friendly_names is None: + friendly_names = load_region_friendly_names() + + # Look up the friendly name in the loaded data + if region_name in friendly_names: + return friendly_names[region_name] + + # Auto-generate if not in map + # Convert region name to title case with proper formatting + return region_name.replace("-", " ").title() + + +def get_all_regions( + session: AuthorizedSession, project: str, quiet: bool = False +) -> list[dict[str, Any]]: + """ + Retrieve the list of all GCE regions using the REST API. + + Args: + session: Authenticated requests session + project: GCE project ID + quiet: Suppress progress messages + + Returns: + list: Sorted list of dictionaries each containing region information + """ + if not quiet: + print("Querying GCE for available regions...", file=sys.stderr) + + try: + api_regions = list_regions(session, project) + + # Load friendly names once for efficiency + friendly_names = load_region_friendly_names() + + regions = [] + for region in api_regions: + region_name = region["name"] + # Count zones from the zones list in the API response + zone_count = len(region.get("zones", [])) + regions.append( + { + "region_name": region_name, + "kconfig_name": get_region_kconfig_name(region_name), + "friendly_name": get_region_friendly_name( + region_name, friendly_names + ), + "status": region.get("status", "UP"), + "zone_count": zone_count, + } + ) + + if not quiet: + print(f"Found {len(regions)} GCE regions", file=sys.stderr) + + return sorted(regions, key=lambda x: x["region_name"]) + + except Exception as e: + if not quiet: + print(f"Error retrieving GCE regions: {e}", file=sys.stderr) + return [] + + +def get_all_zones_by_region( + session: AuthorizedSession, project: str, quiet: bool = False +) -> dict[str, list[dict[str, Any]]]: + """ + Get all zones grouped by region in a single API call. + + This is more efficient than querying zones per-region when we need + zone information for all regions. + + Args: + session: Authenticated requests session + project: GCE project ID + quiet (bool): Suppress debug messages + + Returns: + dict: Dictionary mapping region names to lists of zone dictionaries + """ + if not quiet: + print("Querying all GCE zones...", file=sys.stderr) + + try: + api_zones = list_zones(session, project) + + zones_by_region = {} + for zone in api_zones: + zone_name = zone["name"] + # Extract region from zone name (e.g., "us-west2-a" -> "us-west2") + # Zone format is region-letter, so rsplit on last hyphen + region_name = zone_name.rsplit("-", 1)[0] + + if region_name not in zones_by_region: + zones_by_region[region_name] = [] + + zones_by_region[region_name].append( + { + "zone_name": zone_name, + "kconfig_name": get_zone_kconfig_name(zone_name), + "status": zone.get("status", "UP"), + } + ) + + # Sort zones within each region + for region_name in zones_by_region: + zones_by_region[region_name].sort(key=lambda x: x["zone_name"]) + + if not quiet: + total_zones = sum(len(z) for z in zones_by_region.values()) + print( + f"Found {total_zones} zones across {len(zones_by_region)} regions", + file=sys.stderr, + ) + + return zones_by_region + + except Exception as e: + if not quiet: + print(f"Error retrieving zones: {e}", file=sys.stderr) + return {} + + +def get_region_zones( + session: AuthorizedSession, project: str, region_name: str, quiet: bool = False +) -> list[dict[str, Any]]: + """ + Get all zones for a specific region. + + Args: + session: Authenticated requests session + project: GCE project ID + region_name (str): GCE region name (e.g., 'us-west2') + quiet (bool): Suppress debug messages + + Returns: + list: List of zone dictionaries, or empty list on error + """ + if not quiet: + print( + f"Querying zones for region {region_name}...", + file=sys.stderr, + ) + + try: + api_zones = list_zones(session, project) + + zones = [] + for zone in api_zones: + zone_name = zone["name"] + # Filter to zones in the specified region + # Zone names are like "us-west2-a", region is "us-west2" + if zone_name.rsplit("-", 1)[0] == region_name: + zones.append( + { + "zone_name": zone_name, + "kconfig_name": get_zone_kconfig_name(zone_name), + "status": zone.get("status", "UP"), + } + ) + + if not quiet: + print( + f"Found {len(zones)} zones in {region_name}", + file=sys.stderr, + ) + + return sorted(zones, key=lambda x: x["zone_name"]) + + except Exception as e: + if not quiet: + print(f"Error retrieving zones for {region_name}: {e}", file=sys.stderr) + return [] + + +def get_region_info( + session: AuthorizedSession, + project: str, + regions: list[dict[str, Any]], + region_name: str, + quiet: bool = False, +) -> Optional[dict[str, Any]]: + """ + Get detailed information about a specific region including zones. + + Args: + session: Authenticated requests session + project: GCE project ID + regions (list): List of all available regions + region_name (str): GCE region name (e.g., 'us-west2') + quiet (bool): Suppress debug messages + + Returns: + dict: Dictionary containing region information and zones + """ + if not quiet: + print(f"Querying information for region {region_name}...", file=sys.stderr) + + region_info = next((r for r in regions if r["region_name"] == region_name), None) + + if not region_info: + if not quiet: + print(f"Region {region_name} was not found", file=sys.stderr) + return None + + # Get zones for this region + zones = get_region_zones(session, project, region_name, quiet) + + result = { + "region_name": region_info["region_name"], + "kconfig_name": region_info["kconfig_name"], + "friendly_name": region_info["friendly_name"], + "status": region_info["status"], + "zone_count": len(zones), + "zones": zones, + } + + return result + + +def output_region_kconfig(region_info: dict[str, Any]) -> None: + """Output region information in Kconfig format.""" + environment = get_jinja2_environment() + template = environment.get_template("zone.j2") + + # Determine default zone (first zone alphabetically) + default_zone = ( + region_info["zones"][0]["kconfig_name"] if region_info["zones"] else "" + ) + + print( + template.render( + region_kconfig_name=region_info["kconfig_name"], + default_zone=default_zone, + zones=region_info["zones"], + ) + ) + + +def output_region_raw(region_info: dict[str, Any], quiet: bool = False) -> None: + """Output region information in table format.""" + if not quiet: + print(f"Region: {region_info['region_name']}") + print(f"Friendly Name: {region_info['friendly_name']}") + print(f"Status: {region_info['status']}") + print(f"Zones: {region_info['zone_count']}") + + print(f"{'Zone Name':<20} {'Status':<10}") + print("-" * 30) + + for zone in region_info["zones"]: + print(f"{zone['zone_name']:<20} {zone['status']:<10}") + + +def output_regions_kconfig(regions: list[dict[str, Any]]) -> None: + """Output available regions in Kconfig format.""" + environment = get_jinja2_environment() + template = environment.get_template("regions.j2") + + default_region = get_region_kconfig_name(get_default_region()) + + print( + template.render( + default_region=default_region, + regions=regions, + ) + ) + + +def output_regions_raw(regions: list[dict[str, Any]], quiet: bool = False) -> None: + """Output available regions in table format.""" + if not quiet: + print(f"Available GCE regions ({len(regions)}):\n") + print(f"{'Region Name':<30} {'Status':<10} {'Zones':<8}") + print("-" * 50) + + for region in regions: + print( + f"{region['region_name']:<30} {region['status']:<10} " + f"{region['zone_count']:<8}" + ) + + +def output_locations_kconfig( + session: AuthorizedSession, + project: str, + regions: list[dict[str, Any]], + quiet: bool = False, + zones_by_region: Optional[dict[str, list[dict[str, Any]]]] = None, +) -> None: + """ + Output the complete locations menu in Kconfig format. + + Args: + session: Authenticated requests session + project: GCE project ID + regions (list): List of all regions + quiet (bool): Suppress progress messages + zones_by_region: Optional pre-fetched zones dict (for parallel fetching) + """ + environment = get_jinja2_environment() + + # Output the region choice menu + template = environment.get_template("regions.j2") + default_region = get_region_kconfig_name(get_default_region()) + + print( + template.render( + default_region=default_region, + regions=regions, + ) + ) + + # Use pre-fetched zones if provided, otherwise fetch now + if zones_by_region is None: + zones_by_region = get_all_zones_by_region(session, project, quiet) + + # Output zone configuration for each region + template = environment.get_template("zone.j2") + for region in regions: + region_name = region["region_name"] + zones = zones_by_region.get(region_name, []) + + if zones: + # Determine default zone (first zone alphabetically) + default_zone = zones[0]["kconfig_name"] + print() + print( + template.render( + region_kconfig_name=region["kconfig_name"], + default_zone=default_zone, + zones=zones, + ) + ) + + +def parse_arguments() -> argparse.Namespace: + """Parse command line arguments.""" + parser = argparse.ArgumentParser( + description="Get GCE region and zone information", + formatter_class=argparse.RawDescriptionHelpFormatter, + epilog=""" +Examples: + python %(prog)s --regions + python %(prog)s us-west2 + python %(prog)s asia-south1 --quiet + python %(prog)s > ../kconfigs/Kconfig.location + """, + ) + parser.add_argument( + "region_name", + nargs="?", + help="GCE region name (e.g., us-west2, asia-south1)", + ) + + parser.add_argument( + "--format", + "-f", + choices=["raw", "kconfig"], + default="kconfig", + help="Output format (default: kconfig)", + ) + parser.add_argument( + "--quiet", "-q", action="store_true", help="Suppress informational messages" + ) + parser.add_argument( + "--regions", action="store_true", help="List all available GCE regions" + ) + return parser.parse_args() + + +def main() -> None: + """Main function to run the program.""" + args = parse_arguments() + + # Allow make dynconfig to succeed without GCE credentials + try: + session, project = require_gce_credentials() + except GceNotConfiguredError: + if not args.quiet: + print("GCE not configured - skipping (optional)", file=sys.stderr) + sys.exit(0) + + if not args.quiet: + print(f"Using project: {project}", file=sys.stderr) + + # For the default case (full Kconfig generation), fetch regions and zones + # in parallel to reduce wall-clock time + if not args.regions and not args.region_name: + if not args.quiet: + print("Querying GCE regions and zones...", file=sys.stderr) + + with ThreadPoolExecutor(max_workers=2) as executor: + future_regions = executor.submit( + get_all_regions, session, project, args.quiet + ) + future_zones = executor.submit( + get_all_zones_by_region, session, project, args.quiet + ) + try: + regions = future_regions.result() + zones_by_region = future_zones.result() + except Exception as e: + # Cancel any pending futures + future_regions.cancel() + future_zones.cancel() + print( + f"Error during parallel GCE API queries: {e}", + file=sys.stderr, + ) + sys.exit(1) + + exit_on_empty_result(zones_by_region, "GCE zones query", args.quiet) + + if not args.quiet: + total_zones = sum(len(z) for z in zones_by_region.values()) + print( + f"Found {len(regions)} regions and {total_zones} zones", + file=sys.stderr, + ) + + output_locations_kconfig( + session, project, regions, args.quiet, zones_by_region + ) + return + + # For other cases, fetch only what's needed + regions = get_all_regions(session, project, args.quiet) + exit_on_empty_result(regions, "GCE region query", args.quiet) + + if args.regions: + if args.format == "kconfig": + output_regions_kconfig(regions) + else: + output_regions_raw(regions, args.quiet) + return + + if args.region_name: + region_info = get_region_info( + session, project, regions, args.region_name, args.quiet + ) + if region_info: + if args.format == "kconfig": + output_region_kconfig(region_info) + else: + output_region_raw(region_info, args.quiet) + else: + print( + f"Could not retrieve information for region '{args.region_name}'.", + file=sys.stderr, + ) + print( + "Try running with --regions to see available regions.", file=sys.stderr + ) + sys.exit(1) + + +if __name__ == "__main__": + main() diff --git a/terraform/gce/scripts/region_friendly_names.yml b/terraform/gce/scripts/region_friendly_names.yml new file mode 100644 index 000000000..48b8d795d --- /dev/null +++ b/terraform/gce/scripts/region_friendly_names.yml @@ -0,0 +1,89 @@ +# GCE Region Friendly Names +# +# This file maps GCE region identifiers to human-friendly display names +# used in the kdevops Kconfig menus. +# +# Canonical Source: +# https://cloud.google.com/compute/docs/regions-zones +# (Official Google Cloud Compute Engine Regions and Zones page) +# +# Last Verified: 2025-12-04 +# +# Format: +# region-identifier: "Friendly Display Name" +# +# How to update this file: +# ----------------------- +# When Google adds new regions or you want to customize the display names: +# +# 1. Find the official region identifier from GCE: +# $ gcloud compute regions list +# +# 2. Look up the region's friendly name from Google's documentation: +# https://cloud.google.com/compute/docs/regions-zones +# +# 3. Add a new entry following the format above. Use the pattern: +# ", " +# +# 4. After updating this file, regenerate the Kconfig.location file: +# $ cd terraform/gce/scripts +# $ ./gen_kconfig_location > ../kconfigs/Kconfig.location +# +# Region Mappings: +# ---------------- + +# Africa +africa-south1: "Johannesburg, South Africa" + +# Asia Pacific +asia-east1: "Changhua County, Taiwan" +asia-east2: "Hong Kong" +asia-northeast1: "Tokyo, Japan" +asia-northeast2: "Osaka, Japan" +asia-northeast3: "Seoul, South Korea" +asia-south1: "Mumbai, India" +asia-south2: "Delhi, India" +asia-southeast1: "Jurong West, Singapore" +asia-southeast2: "Jakarta, Indonesia" + +# Australia +australia-southeast1: "Sydney, Australia" +australia-southeast2: "Melbourne, Australia" + +# Europe +europe-central2: "Warsaw, Poland" +europe-north1: "Hamina, Finland" +europe-north2: "Stockholm, Sweden" +europe-southwest1: "Madrid, Spain" +europe-west1: "St. Ghislain, Belgium" +europe-west2: "London, UK" +europe-west3: "Frankfurt, Germany" +europe-west4: "Eemshaven, Netherlands" +europe-west6: "Zurich, Switzerland" +europe-west8: "Milan, Italy" +europe-west9: "Paris, France" +europe-west10: "Berlin, Germany" +europe-west12: "Turin, Italy" + +# Middle East +me-central1: "Doha, Qatar" +me-central2: "Dammam, Saudi Arabia" +me-west1: "Tel Aviv, Israel" + +# North America +northamerica-northeast1: "Montreal, Quebec, Canada" +northamerica-northeast2: "Toronto, Ontario, Canada" +northamerica-south1: "Queretaro, Mexico" +us-central1: "Council Bluffs, Iowa, USA" +us-east1: "Moncks Corner, South Carolina, USA" +us-east4: "Ashburn, Virginia, USA" +us-east5: "Columbus, Ohio, USA" +us-south1: "Dallas, Texas, USA" +us-west1: "The Dalles, Oregon, USA" +us-west2: "Los Angeles, California, USA" +us-west3: "Salt Lake City, Utah, USA" +us-west4: "Las Vegas, Nevada, USA" + +# South America +southamerica-east1: "Sao Paulo, Brazil" +southamerica-west1: "Santiago, Chile" diff --git a/terraform/gce/scripts/regions.j2 b/terraform/gce/scripts/regions.j2 new file mode 100644 index 000000000..eafd67395 --- /dev/null +++ b/terraform/gce/scripts/regions.j2 @@ -0,0 +1,29 @@ +choice + prompt "GCE region" + default TERRAFORM_GCE_REGION_{{ default_region }} + help + GCE regions are collections of co-located zones. Zones have + high-bandwidth, low-latency network connections to other + zones within the same region. + + For details: + https://cloud.google.com/compute/docs/regions-zones/ + + For guidance selecting a region to use, try: + https://cloud.withgoogle.com/region-picker/ + +{% for region in regions %} +config TERRAFORM_GCE_REGION_{{ region['kconfig_name'] }} + bool "{{ region['region_name'] }}" + help + {{ region['friendly_name'] }} + +{% endfor %} +endchoice + +config TERRAFORM_GCE_REGION + string + output yaml +{% for region in regions %} + default "{{ region['region_name'] }}" if TERRAFORM_GCE_REGION_{{ region['kconfig_name'] }} +{% endfor %} diff --git a/terraform/gce/scripts/zone.j2 b/terraform/gce/scripts/zone.j2 new file mode 100644 index 000000000..78760c5d1 --- /dev/null +++ b/terraform/gce/scripts/zone.j2 @@ -0,0 +1,23 @@ +if TERRAFORM_GCE_REGION_{{ region_kconfig_name }} + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_{{ default_zone }} + help + A zone is a deployment area within a region. + +{% for zone in zones %} +config TERRAFORM_GCE_ZONE_{{ zone['kconfig_name'] }} + bool "{{ zone['zone_name'] }}" + +{% endfor %} +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml +{% for zone in zones %} + default "{{ zone['zone_name'] }}" if TERRAFORM_GCE_ZONE_{{ zone['kconfig_name'] }} +{% endfor %} + +endif # TERRAFORM_GCE_REGION_{{ region_kconfig_name }} From f16014d9b9e96f5fc2800a7df6e5a607f9c7b5cb Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2025 16:41:26 -0500 Subject: [PATCH 6/8] terraform/gce: Generate Kconfig.machine dynamically Similar to commit 0e572ac21f4d ("terraform/oci: Generate Kconfig.shapes dynamically"), this patch adds a Python script that queries the Google Cloud API to dynamically generate a Kconfig menu for machine types. Usage: ./gen_kconfig_machine > ../kconfigs/Kconfig.machine ./gen_kconfig_machine --series ./gen_kconfig_machine n2-standard ./gen_kconfig_machine --zone us-west2-a --series The script uses the GCE REST API directly to match existing GCE script patterns. It properly handles machine type series grouping such as n2-standard and n2-highcpu, correctly identifies variants like local SSD and bare metal configurations, and includes appropriate architecture dependencies for x86_64 and arm64 platforms. Generated-by: Claude AI Signed-off-by: Chuck Lever --- terraform/gce/scripts/gce_common.py | 87 ++ terraform/gce/scripts/gen_kconfig_machine | 961 ++++++++++++++++++++++ terraform/gce/scripts/machine_type.j2 | 33 + terraform/gce/scripts/series.j2 | 40 + 4 files changed, 1121 insertions(+) create mode 100755 terraform/gce/scripts/gen_kconfig_machine create mode 100644 terraform/gce/scripts/machine_type.j2 create mode 100644 terraform/gce/scripts/series.j2 diff --git a/terraform/gce/scripts/gce_common.py b/terraform/gce/scripts/gce_common.py index c6cf744ca..c115aaafa 100644 --- a/terraform/gce/scripts/gce_common.py +++ b/terraform/gce/scripts/gce_common.py @@ -357,3 +357,90 @@ def require_gce_credentials(): raise GceNotConfiguredError(str(e)) from e except google.auth.exceptions.DefaultCredentialsError as e: raise GceNotConfiguredError("GCE credentials not found") from e + + +# Fields needed for machine type Kconfig generation +MACHINE_TYPE_FIELDS = ( + "name,guestCpus,memoryMb,isSharedCpu,description," + "maximumPersistentDisks,maximumPersistentDisksSizeGb" +) + + +def list_machine_types( + session: requests.Session, project: str, zone: str +) -> list[dict]: + """ + List all GCE machine types for a specific zone using the REST API. + + Args: + session: Authenticated requests session + project: GCE project ID + zone: GCE zone name (e.g., 'us-west2-a') + + Returns: + list: List of machine type dictionaries from the API + """ + url = f"{GCE_COMPUTE_API}/projects/{project}/zones/{zone}/machineTypes" + # Request only needed fields to reduce response size and latency + params = {"fields": f"items({MACHINE_TYPE_FIELDS})"} + response = session.get(url, params=params, timeout=GCE_API_TIMEOUT) + response.raise_for_status() + + data = response.json() + return data.get("items", []) + + +def list_machine_types_aggregated( + session: requests.Session, project: str +) -> dict[str, list[dict]]: + """ + List all GCE machine types across all zones using the aggregated API. + + This is more efficient than querying each zone separately when we need + machine type information across multiple zones. + + Args: + session: Authenticated requests session + project: GCE project ID + + Returns: + dict: Dictionary mapping zone names to lists of machine type dicts + """ + url = f"{GCE_COMPUTE_API}/projects/{project}/aggregated/machineTypes" + # Request only needed fields to reduce response size and latency + params = {"fields": f"items/*/machineTypes({MACHINE_TYPE_FIELDS}),nextPageToken"} + all_machine_types = {} + + while True: + response = session.get(url, params=params, timeout=GCE_API_TIMEOUT) + response.raise_for_status() + data = response.json() + + for zone_key, zone_data in data.get("items", {}).items(): + # zone_key is like "zones/us-west2-a" + if zone_key.startswith("zones/"): + zone_name = zone_key.split("/")[1] + machine_types = zone_data.get("machineTypes", []) + if machine_types: + all_machine_types[zone_name] = machine_types + + # Handle pagination + next_page = data.get("nextPageToken") + if not next_page: + break + params["pageToken"] = next_page + + return all_machine_types + + +def get_machine_type_kconfig_name(machine_type: str) -> str: + """ + Convert GCE machine type name to Kconfig constant name. + + Args: + machine_type (str): GCE machine type (e.g., 'n2-standard-4', 'e2-micro') + + Returns: + str: Kconfig constant name (e.g., 'N2_STANDARD_4', 'E2_MICRO') + """ + return machine_type.upper().replace("-", "_") diff --git a/terraform/gce/scripts/gen_kconfig_machine b/terraform/gce/scripts/gen_kconfig_machine new file mode 100755 index 000000000..9f88edfe6 --- /dev/null +++ b/terraform/gce/scripts/gen_kconfig_machine @@ -0,0 +1,961 @@ +#!/usr/bin/env python3 +# ex: set filetype=python: + +""" +Retrieve machine type information from GCE. Use it to construct the +"machine types" Kconfig menu. + +GCE machine types represent compute instance configurations with varying +combinations of CPU, memory, and capabilities. This script queries the GCE +API to discover available machine types and generates Kconfig menu entries +for them. + +Machine Type Series: + GCE machine types are organized into series by combining family and + workload type: + - n2-standard: General purpose balanced (Intel) + - n2-highcpu: General purpose compute-optimized (Intel) + - n2-highmem: General purpose memory-optimized (Intel) + - n2d-standard: General purpose balanced (AMD) + - e2-standard: Cost-optimized balanced + - c2-standard: Compute-optimized + - etc. + + This script organizes machine types by series and generates a two-level + Kconfig menu: first select the series, then select the specific machine + type within that series. + +Usage: + # Generate complete Kconfig.compute file + ./gen_kconfig_machine > ../kconfigs/Kconfig.compute + + # List all available machine type series + ./gen_kconfig_machine --series + + # Get details for a specific series + ./gen_kconfig_machine n2-standard +""" + +from __future__ import annotations + +import sys +import argparse +import re + +import requests +import requests.exceptions + +from gce_common import ( + GceNotConfiguredError, + get_default_zone, + get_jinja2_environment, + get_machine_type_kconfig_name, + list_machine_types, + list_machine_types_aggregated, + exit_on_empty_result, + require_gce_credentials, +) + + +# Series metadata for help text +SERIES_METADATA = { + "a2-highgpu": { + "description": "A2 High GPU", + "help_text": "GPU-enabled machine types with NVIDIA A100 GPUs for ML and HPC workloads.", + "architecture": "x86_64", + }, + "a2-megagpu": { + "description": "A2 Mega GPU", + "help_text": "GPU-enabled machine types with multiple NVIDIA A100 GPUs.", + "architecture": "x86_64", + }, + "a2-ultragpu": { + "description": "A2 Ultra GPU", + "help_text": "GPU-enabled machine types with NVIDIA A100 80GB GPUs.", + "architecture": "x86_64", + }, + "a3-highgpu": { + "description": "A3 High GPU", + "help_text": "GPU-enabled machine types with NVIDIA H100 GPUs.", + "architecture": "x86_64", + }, + "a3-megagpu": { + "description": "A3 Mega GPU", + "help_text": "GPU-enabled machine types with multiple NVIDIA H100 GPUs.", + "architecture": "x86_64", + }, + "c2-standard": { + "description": "C2 Standard", + "help_text": "Compute-optimized with 3.8 GHz sustained all-core turbo on Intel Cascade Lake.", + "architecture": "x86_64", + }, + "c2d-highcpu": { + "description": "C2D High CPU", + "help_text": "Compute-optimized high CPU with AMD EPYC Milan processors.", + "architecture": "x86_64", + }, + "c2d-highmem": { + "description": "C2D High Memory", + "help_text": "Compute-optimized high memory with AMD EPYC Milan processors.", + "architecture": "x86_64", + }, + "c2d-standard": { + "description": "C2D Standard", + "help_text": "Compute-optimized balanced with AMD EPYC Milan processors.", + "architecture": "x86_64", + }, + "c3-highcpu": { + "description": "C3 High CPU", + "help_text": "Third generation compute-optimized high CPU with Intel Sapphire Rapids.", + "architecture": "x86_64", + }, + "c3-highmem": { + "description": "C3 High Memory", + "help_text": "Third generation compute-optimized high memory with Intel Sapphire Rapids.", + "architecture": "x86_64", + }, + "c3-standard": { + "description": "C3 Standard", + "help_text": "Third generation compute-optimized balanced with Intel Sapphire Rapids.", + "architecture": "x86_64", + }, + "c3d-highcpu": { + "description": "C3D High CPU", + "help_text": "Third generation compute-optimized high CPU with AMD EPYC Genoa.", + "architecture": "x86_64", + }, + "c3d-highmem": { + "description": "C3D High Memory", + "help_text": "Third generation compute-optimized high memory with AMD EPYC Genoa.", + "architecture": "x86_64", + }, + "c3d-standard": { + "description": "C3D Standard", + "help_text": "Third generation compute-optimized balanced with AMD EPYC Genoa.", + "architecture": "x86_64", + }, + "c4-highcpu": { + "description": "C4 High CPU", + "help_text": "Fourth generation compute-optimized high CPU with Intel Emerald Rapids.", + "architecture": "x86_64", + }, + "c4-highmem": { + "description": "C4 High Memory", + "help_text": "Fourth generation compute-optimized high memory with Intel Emerald Rapids.", + "architecture": "x86_64", + }, + "c4-standard": { + "description": "C4 Standard", + "help_text": "Fourth generation compute-optimized balanced with Intel Emerald Rapids.", + "architecture": "x86_64", + }, + "c4a-highcpu": { + "description": "C4A High CPU", + "help_text": "Fourth generation compute-optimized high CPU with Arm-based Axion processors.", + "architecture": "arm64", + }, + "c4a-highmem": { + "description": "C4A High Memory", + "help_text": "Fourth generation compute-optimized high memory with Arm-based Axion processors.", + "architecture": "arm64", + }, + "c4a-standard": { + "description": "C4A Standard", + "help_text": "Fourth generation compute-optimized balanced with Arm-based Axion processors.", + "architecture": "arm64", + }, + "e2-highcpu": { + "description": "E2 High CPU", + "help_text": "Cost-optimized compute-intensive on Intel or AMD processors.", + "architecture": "x86_64", + }, + "e2-highmem": { + "description": "E2 High Memory", + "help_text": "Cost-optimized memory-intensive on Intel or AMD processors.", + "architecture": "x86_64", + }, + "e2-medium": { + "description": "E2 Medium", + "help_text": "Cost-optimized shared-core machine with 2 vCPUs and 4 GB memory.", + "architecture": "x86_64", + }, + "e2-micro": { + "description": "E2 Micro", + "help_text": "Cost-optimized shared-core machine with 2 vCPUs and 1 GB memory.", + "architecture": "x86_64", + }, + "e2-small": { + "description": "E2 Small", + "help_text": "Cost-optimized shared-core machine with 2 vCPUs and 2 GB memory.", + "architecture": "x86_64", + }, + "e2-standard": { + "description": "E2 Standard", + "help_text": "Cost-optimized balanced on Intel or AMD processors.", + "architecture": "x86_64", + }, + "f1-micro": { + "description": "F1 Micro", + "help_text": "Legacy shared-core machine type. Consider using e2-micro instead.", + "architecture": "x86_64", + }, + "g1-small": { + "description": "G1 Small", + "help_text": "Legacy shared-core machine type. Consider using e2-small instead.", + "architecture": "x86_64", + }, + "g2-standard": { + "description": "G2 Standard", + "help_text": "GPU-enabled machine types with NVIDIA L4 GPUs.", + "architecture": "x86_64", + }, + "h3-standard": { + "description": "H3 Standard", + "help_text": "HPC-optimized with Intel Sapphire Rapids for tightly-coupled HPC workloads.", + "architecture": "x86_64", + }, + "m1-megamem": { + "description": "M1 Mega Memory", + "help_text": "Memory-optimized with up to 1.4 TB of memory.", + "architecture": "x86_64", + }, + "m1-ultramem": { + "description": "M1 Ultra Memory", + "help_text": "Memory-optimized with up to 3.8 TB of memory.", + "architecture": "x86_64", + }, + "m2-megamem": { + "description": "M2 Mega Memory", + "help_text": "Second generation memory-optimized with up to 6 TB of memory.", + "architecture": "x86_64", + }, + "m2-hypermem": { + "description": "M2 Hyper Memory", + "help_text": "Second generation memory-optimized with high memory-to-CPU ratio.", + "architecture": "x86_64", + }, + "m2-ultramem": { + "description": "M2 Ultra Memory", + "help_text": "Second generation memory-optimized with up to 12 TB of memory.", + "architecture": "x86_64", + }, + "m3-megamem": { + "description": "M3 Mega Memory", + "help_text": "Third generation memory-optimized with Intel Ice Lake.", + "architecture": "x86_64", + }, + "m3-ultramem": { + "description": "M3 Ultra Memory", + "help_text": "Third generation memory-optimized with Intel Ice Lake.", + "architecture": "x86_64", + }, + "n1-highcpu": { + "description": "N1 High CPU", + "help_text": "First generation compute-intensive on Intel Haswell/Broadwell/Skylake.", + "architecture": "x86_64", + }, + "n1-highmem": { + "description": "N1 High Memory", + "help_text": "First generation memory-intensive on Intel Haswell/Broadwell/Skylake.", + "architecture": "x86_64", + }, + "n1-megamem": { + "description": "N1 Mega Memory", + "help_text": "First generation very high memory on Intel Skylake.", + "architecture": "x86_64", + }, + "n1-standard": { + "description": "N1 Standard", + "help_text": "First generation balanced on Intel Haswell/Broadwell/Skylake.", + "architecture": "x86_64", + }, + "n1-ultramem": { + "description": "N1 Ultra Memory", + "help_text": "First generation ultra-high memory on Intel Broadwell E7.", + "architecture": "x86_64", + }, + "n2-highcpu": { + "description": "N2 High CPU", + "help_text": "Second generation compute-intensive on Intel Cascade Lake or Ice Lake.", + "architecture": "x86_64", + }, + "n2-highmem": { + "description": "N2 High Memory", + "help_text": "Second generation memory-intensive on Intel Cascade Lake or Ice Lake.", + "architecture": "x86_64", + }, + "n2-standard": { + "description": "N2 Standard", + "help_text": "Second generation balanced on Intel Cascade Lake or Ice Lake.", + "architecture": "x86_64", + }, + "n2d-highcpu": { + "description": "N2D High CPU", + "help_text": "Second generation compute-intensive on AMD EPYC Rome or Milan.", + "architecture": "x86_64", + }, + "n2d-highmem": { + "description": "N2D High Memory", + "help_text": "Second generation memory-intensive on AMD EPYC Rome or Milan.", + "architecture": "x86_64", + }, + "n2d-standard": { + "description": "N2D Standard", + "help_text": "Second generation balanced on AMD EPYC Rome or Milan.", + "architecture": "x86_64", + }, + "n4-highcpu": { + "description": "N4 High CPU", + "help_text": "Fourth generation compute-intensive on Intel Emerald Rapids.", + "architecture": "x86_64", + }, + "n4-highmem": { + "description": "N4 High Memory", + "help_text": "Fourth generation memory-intensive on Intel Emerald Rapids.", + "architecture": "x86_64", + }, + "n4-standard": { + "description": "N4 Standard", + "help_text": "Fourth generation balanced on Intel Emerald Rapids.", + "architecture": "x86_64", + }, + "t2a-standard": { + "description": "T2A Standard", + "help_text": "Arm-based machines with Ampere Altra processors. Cost-effective for scale-out.", + "architecture": "arm64", + }, + "t2d-standard": { + "description": "T2D Standard", + "help_text": "Scale-out optimized on AMD EPYC Milan. Good for web and containerized workloads.", + "architecture": "x86_64", + }, + "z3-highmem": { + "description": "Z3 High Memory", + "help_text": "Storage-optimized with large local SSD capacity for databases and analytics.", + "architecture": "x86_64", + }, + "z3-standard": { + "description": "Z3 Standard", + "help_text": "Storage-optimized with local SSD capacity for databases and analytics.", + "architecture": "x86_64", + }, +} + + +def extract_machine_series(machine_type_name: str) -> str: + """ + Extract machine series from the machine type name. + + The series includes both family and workload type: + - n2-standard-4 -> n2-standard + - e2-highmem-8 -> e2-highmem + - c2d-highcpu-112 -> c2d-highcpu + - e2-micro -> e2-micro (single machine in series) + - c3-standard-176-lssd -> c3-standard (lssd = local SSD variant) + - c3-highcpu-192-metal -> c3-highcpu (metal = bare metal variant) + - a2-highgpu-1g -> a2-highgpu (1g = GPU count variant) + + Args: + machine_type_name (str): GCE machine type name + + Returns: + str: Series name (e.g., 'n2-standard', 'e2-highmem') + """ + parts = machine_type_name.split("-") + + # Handle special single-machine series (e2-micro, e2-small, etc.) + # and any other two-part names + if len(parts) == 2: + return machine_type_name + + # Known workload types that form the series + workload_types = { + "standard", + "highcpu", + "highmem", + "megamem", + "ultramem", + "hypermem", + "highgpu", + "megagpu", + "ultragpu", + "edgegpu", + } + + # Find the workload type component + for i, part in enumerate(parts): + if part in workload_types: + # Series is family + workload type + return "-".join(parts[: i + 1]) + + # Fallback: try to extract series by removing trailing numeric/variant parts + if len(parts) >= 2: + # Remove trailing parts that are numeric or variant suffixes + variant_suffixes = {"lssd", "metal", "nolssd"} + result_parts = [] + for part in parts: + if part.isdigit(): + break + if part in variant_suffixes: + break + # Handle GPU size indicators like "1g", "2g", "8g", "16g" + if re.match(r"^\d+g$", part): + break + result_parts.append(part) + + if result_parts: + return "-".join(result_parts) + + return machine_type_name + + +def extract_machine_family(machine_type_name: str) -> str: + """ + Extract machine family from the machine type name. + + Examples: + - n2-standard-4 -> n2 + - e2-micro -> e2 + - c2d-highcpu-8 -> c2d + + Args: + machine_type_name (str): GCE machine type name + + Returns: + str: Family name (e.g., 'n2', 'e2', 'c2d') + """ + parts = machine_type_name.split("-") + return parts[0] if parts else machine_type_name + + +def parse_all_machine_series(machine_types: list[dict]) -> dict[str, dict]: + """ + Extract machine series from the list of machine types. + + Args: + machine_types: List of machine type dictionaries + + Returns: + Dictionary with series info including count of types per series + """ + series_dict = {} + seen_types = set() + + for machine_type in machine_types: + type_name = machine_type.get("name") + if not type_name: + continue + + # Skip duplicate machine type names + if type_name in seen_types: + continue + seen_types.add(type_name) + + # Skip custom machine types + if type_name.startswith("custom-") or "custom" in type_name: + continue + + # Parse machine series from name + series = extract_machine_series(type_name) + family = extract_machine_family(type_name) + + if series not in series_dict: + # Get metadata for this series + metadata = SERIES_METADATA.get( + series, + { + "description": series.replace("-", " ").title(), + "help_text": f"Virtual machines in the {series} series.", + "architecture": "x86_64", + }, + ) + + series_dict[series] = { + "series_name": series, + "family": family, + "type_count": 0, + "min_vcpus": None, + "max_vcpus": 0, + "min_memory_gb": None, + "max_memory_gb": 0, + "description": metadata["description"], + "help_text": metadata["help_text"], + "architecture": metadata["architecture"], + } + + series_dict[series]["type_count"] += 1 + + # Track min/max vCPUs and memory + vcpus = machine_type.get("guestCpus", 0) + memory_gb = machine_type.get("memoryMb", 0) / 1024.0 + + if vcpus > 0: + current_min = series_dict[series]["min_vcpus"] + if current_min is None or vcpus < current_min: + series_dict[series]["min_vcpus"] = vcpus + series_dict[series]["max_vcpus"] = max( + series_dict[series]["max_vcpus"], vcpus + ) + if memory_gb > 0: + current_min = series_dict[series]["min_memory_gb"] + if current_min is None or memory_gb < current_min: + series_dict[series]["min_memory_gb"] = memory_gb + series_dict[series]["max_memory_gb"] = max( + series_dict[series]["max_memory_gb"], memory_gb + ) + + return series_dict + + +def get_machine_series_info( + series_name: str, machine_types: list[dict], quiet: bool = False +) -> list[dict]: + """ + Get machine type information for a specific series. + + Args: + series_name: Machine series name (e.g., 'n2-standard', 'e2-highcpu') + machine_types: List of all machine types + quiet: Suppress debug messages + + Returns: + List of dictionaries containing machine type information + """ + series_types = [] + + for machine_type in machine_types: + type_name = machine_type["name"] + type_series = extract_machine_series(type_name) + + # Skip custom machine types + if type_name.startswith("custom-") or "custom" in type_name: + continue + + # Match types that belong to this series + if type_series == series_name: + series_types.append(machine_type) + + if not series_types: + if not quiet: + print(f"No machine types found in series '{series_name}'.", file=sys.stderr) + return [] + + if not quiet: + print( + f"Found {len(series_types)} machine types in series '{series_name}'", + file=sys.stderr, + ) + + # Extract detailed information + type_info = [] + seen_types = set() + + for machine_type in series_types: + type_name = machine_type["name"] + + # Skip duplicates + if type_name in seen_types: + continue + seen_types.add(type_name) + + vcpus = machine_type.get("guestCpus", 0) + memory_mb = machine_type.get("memoryMb", 0) + memory_gb = memory_mb / 1024.0 + + # Determine if this is a shared-core machine + is_shared_cpu = machine_type.get("isSharedCpu", False) + + type_info.append( + { + "name": type_name, + "kconfig_name": get_machine_type_kconfig_name(type_name), + "vcpus": vcpus, + "memory_gb": memory_gb, + "memory_mb": memory_mb, + "series": series_name, + "is_shared_cpu": is_shared_cpu, + "description": machine_type.get("description", ""), + "max_persistent_disks": machine_type.get("maximumPersistentDisks", 0), + "max_persistent_disks_size_gb": machine_type.get( + "maximumPersistentDisksSizeGb", 0 + ), + } + ) + + # Sort by vCPUs, then memory + type_info.sort(key=lambda x: (x["vcpus"], x["memory_gb"])) + + return type_info + + +def natural_sort_key(machine_type_name: str) -> tuple: + """ + Generate a sort key for natural (numeric) ordering of machine type names. + + Converts names like n2-standard-16 into a tuple that sorts naturally: + n2-standard-1, n2-standard-2, ..., n2-standard-16 instead of alphabetic. + + Args: + machine_type_name: GCE machine type name + + Returns: + Sort key tuple with string and integer components + """ + parts = re.split(r"(\d+)", machine_type_name) + key = [] + for part in parts: + if part.isdigit(): + key.append(int(part)) + else: + key.append(part) + return tuple(key) + + +def get_all_machine_types( + session: requests.Session, + project: str, + zone: str | None = None, + quiet: bool = False, +) -> list[dict]: + """ + Get all available machine types. + + If zone is specified, queries that zone only. Otherwise uses the + aggregated API to get machine types across all zones and deduplicates. + + Args: + session: Authenticated requests session + project: GCE project ID + zone: Optional zone to query (if None, queries all zones) + quiet: Suppress progress messages + + Returns: + List of unique machine type dictionaries + """ + if zone: + if not quiet: + print(f"Querying machine types in zone {zone}...", file=sys.stderr) + try: + return list_machine_types(session, project, zone) + except requests.exceptions.RequestException as e: + if not quiet: + print(f"Error retrieving machine types: {e}", file=sys.stderr) + return [] + + if not quiet: + print("Querying machine types across all zones...", file=sys.stderr) + + try: + types_by_zone = list_machine_types_aggregated(session, project) + + # Deduplicate by machine type name (same type available in multiple zones) + all_types = {} + for zone_name, zone_types in types_by_zone.items(): + for machine_type in zone_types: + type_name = machine_type["name"] + if type_name not in all_types: + all_types[type_name] = machine_type + + result = list(all_types.values()) + if not quiet: + print(f"Found {len(result)} unique machine types", file=sys.stderr) + + return result + + except requests.exceptions.RequestException as e: + if not quiet: + print(f"Error retrieving machine types: {e}", file=sys.stderr) + return [] + + +def output_series_kconfig( + series_dict: dict[str, dict], default_series: str = "n2-standard" +) -> None: + """ + Output machine series in Kconfig format. + + Args: + series_dict: Dictionary of series information + default_series: Default series to select + """ + environment = get_jinja2_environment() + template = environment.get_template("series.j2") + + sorted_series = sorted(series_dict.values(), key=lambda x: x["series_name"]) + default_kconfig = ( + f"TERRAFORM_GCE_MACHINE_FAMILY_{default_series.upper().replace('-', '_')}" + ) + + print( + template.render( + series_list=sorted_series, + default_series_config=default_kconfig, + ) + ) + + +def output_machine_types_kconfig( + machine_types: list[dict], default_type: str = "n2-standard-8" +) -> None: + """ + Output complete machine types menu in Kconfig format. + + This generates a two-level menu: first select series, then select + specific machine type within the series. + + Args: + machine_types: List of all machine types + default_type: Default machine type to select + """ + series_dict = parse_all_machine_series(machine_types) + environment = get_jinja2_environment() + + # Determine default series from default type + default_series = extract_machine_series(default_type) + + # Output the series selection menu + template = environment.get_template("series.j2") + sorted_series = sorted(series_dict.values(), key=lambda x: x["series_name"]) + default_series_config = ( + f"TERRAFORM_GCE_MACHINE_FAMILY_{default_series.upper().replace('-', '_')}" + ) + + print( + template.render( + series_list=sorted_series, + default_series_config=default_series_config, + ) + ) + print() + + # Output machine type selection for each series + template = environment.get_template("machine_type.j2") + for series in sorted_series: + series_types = get_machine_series_info( + series["series_name"], machine_types, quiet=True + ) + if not series_types: + continue + + # Sort by natural order + series_types.sort(key=lambda x: natural_sort_key(x["name"])) + + # Determine default for this series + series_default = None + for t in series_types: + if t["name"] == default_type: + series_default = t["kconfig_name"] + break + if not series_default: + series_default = series_types[0]["kconfig_name"] + + print( + template.render( + series_name=series["series_name"], + series_kconfig_name=series["series_name"].upper().replace("-", "_"), + default_type_config=f"TERRAFORM_GCE_MACHINE_{series_default}", + machine_types=series_types, + help_text=series["help_text"], + architecture=series["architecture"], + ) + ) + print() + + +def output_series_raw(series_dict: dict[str, dict], quiet: bool = False) -> None: + """Output available machine series in table format.""" + if not quiet: + print(f"Available machine type series ({len(series_dict)}):\n") + + print( + f"{'Series':<20} {'Count':<8} {'vCPUs Range':<15} " + f"{'Memory Range (GB)':<20} {'Description':<30}" + ) + print("-" * 95) + + sorted_series = sorted(series_dict.values(), key=lambda x: x["series_name"]) + for series in sorted_series: + min_vcpus = series["min_vcpus"] if series["min_vcpus"] is not None else 0 + min_memory_gb = ( + series["min_memory_gb"] if series["min_memory_gb"] is not None else 0 + ) + vcpus_range = f"{min_vcpus}-{series['max_vcpus']}" + memory_range = f"{min_memory_gb:.1f}-{series['max_memory_gb']:.1f}" + + print( + f"{series['series_name']:<20} " + f"{series['type_count']:<8} " + f"{vcpus_range:<15} " + f"{memory_range:<20} " + f"{series['description']:<30}" + ) + + +def output_series_types_raw(types: list[dict], quiet: bool = False) -> None: + """Output machine type series information in table format.""" + if not quiet: + print(f"Found {len(types)} machine types:\n") + + print(f"{'Machine Type':<25} {'vCPUs':<8} {'Memory (GB)':<15} {'Series':<20}") + print("-" * 70) + + for t in types: + print( + f"{t['name']:<25} " + f"{t['vcpus']:<8} " + f"{t['memory_gb']:<15.1f} " + f"{t['series']:<20}" + ) + + +def parse_arguments() -> argparse.Namespace: + """Parse command line arguments.""" + default_zone = get_default_zone() + parser = argparse.ArgumentParser( + description="Get GCE machine type information", + formatter_class=argparse.RawDescriptionHelpFormatter, + epilog=f""" +Examples: + # Generate Kconfig for machine types (uses default zone: {default_zone}) + python %(prog)s > ../kconfigs/Kconfig.machine + + # Generate Kconfig with all machine types from all zones (slower) + python %(prog)s --all-zones > ../kconfigs/Kconfig.machine + + # List all available series + python %(prog)s --series + + # Query specific machine type series + python %(prog)s n2-standard + + # Query a different zone + python %(prog)s --zone us-central1-a --series + """, + ) + parser.add_argument( + "series_name", + nargs="?", + help="Machine type series name (e.g., n2-standard, e2-highcpu, c2d-standard)", + ) + + parser.add_argument( + "--series", + action="store_true", + help="List all available machine type series", + ) + parser.add_argument( + "--format", + "-f", + choices=["raw", "kconfig"], + default="kconfig", + help="Output format (default: kconfig)", + ) + parser.add_argument( + "--quiet", "-q", action="store_true", help="Suppress informational messages" + ) + parser.add_argument( + "--zone", + "-z", + default=default_zone, + help=f"Query specific zone (default: {default_zone})", + ) + parser.add_argument( + "--all-zones", + action="store_true", + help="Query all zones for complete machine type coverage (slower)", + ) + return parser.parse_args() + + +def main() -> None: + """Main function to run the program.""" + args = parse_arguments() + + # Allow make dynconfig to succeed without GCE credentials + try: + session, project = require_gce_credentials() + except GceNotConfiguredError: + if not args.quiet: + print("GCE not configured - skipping (optional)", file=sys.stderr) + sys.exit(0) + + if not args.quiet: + print(f"Using project: {project}", file=sys.stderr) + + # Determine zone to query: use all zones only if explicitly requested + zone = None if args.all_zones else args.zone + + if not args.quiet: + if zone: + print(f"Querying zone: {zone}", file=sys.stderr) + else: + print("Querying all zones (this may take a while)...", file=sys.stderr) + + # Get machine types + machine_types = get_all_machine_types(session, project, zone, args.quiet) + exit_on_empty_result(machine_types, "GCE machine type query", args.quiet) + + if args.series: + series_dict = parse_all_machine_series(machine_types) + if args.format == "kconfig": + output_series_kconfig(series_dict) + else: + output_series_raw(series_dict, args.quiet) + return + + if args.series_name: + if not args.quiet: + print( + f"Fetching information for the {args.series_name} series...", + file=sys.stderr, + ) + + series_types = get_machine_series_info( + args.series_name, machine_types, args.quiet + ) + + if not series_types: + print( + f"No machine types found for series '{args.series_name}'.", + file=sys.stderr, + ) + print( + "Try running with --series to see available series.", + file=sys.stderr, + ) + sys.exit(1) + + if args.format == "kconfig": + environment = get_jinja2_environment() + template = environment.get_template("machine_type.j2") + series_types.sort(key=lambda x: natural_sort_key(x["name"])) + + # Get series metadata + metadata = SERIES_METADATA.get( + args.series_name, + { + "help_text": f"Virtual machines in the {args.series_name} series.", + "architecture": "x86_64", + }, + ) + + print( + template.render( + series_name=args.series_name, + series_kconfig_name=args.series_name.upper().replace("-", "_"), + default_type_config=f"TERRAFORM_GCE_MACHINE_{series_types[0]['kconfig_name']}", + machine_types=series_types, + help_text=metadata["help_text"], + architecture=metadata["architecture"], + ) + ) + else: + output_series_types_raw(series_types, args.quiet) + return + + # Output complete Kconfig + output_machine_types_kconfig(machine_types) + + +if __name__ == "__main__": + main() diff --git a/terraform/gce/scripts/machine_type.j2 b/terraform/gce/scripts/machine_type.j2 new file mode 100644 index 000000000..bfaed1fd6 --- /dev/null +++ b/terraform/gce/scripts/machine_type.j2 @@ -0,0 +1,33 @@ +if TERRAFORM_GCE_MACHINE_FAMILY_{{ series_kconfig_name }} + +choice + prompt "GCE Machine type" + default {{ default_type_config }} + help + {{ help_text }} + +{% for machine in machine_types %} +config TERRAFORM_GCE_MACHINE_{{ machine.kconfig_name }} + bool "{{ machine.name }}" +{% if architecture == 'arm64' %} + depends on TARGET_ARCH_ARM64 +{% else %} + depends on TARGET_ARCH_X86_64 +{% endif %} + help + {{ machine.vcpus }} vCPU{{ 's' if machine.vcpus > 1 else '' }}{% if machine.vcpus >= 2 %} ({{ (machine.vcpus / 2)|int }} core{{ 's' if (machine.vcpus / 2)|int > 1 else '' }}){% endif %} and {{ machine.memory_gb|int if machine.memory_gb == machine.memory_gb|int else machine.memory_gb|round(1) }}GB of memory. +{% if machine.is_shared_cpu %} + Shared-core machine type. +{% endif %} + +{% endfor %} +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml +{% for machine in machine_types %} + default "{{ machine.name }}" if TERRAFORM_GCE_MACHINE_{{ machine.kconfig_name }} +{% endfor %} + +endif # TERRAFORM_GCE_MACHINE_FAMILY_{{ series_kconfig_name }} diff --git a/terraform/gce/scripts/series.j2 b/terraform/gce/scripts/series.j2 new file mode 100644 index 000000000..6e0576535 --- /dev/null +++ b/terraform/gce/scripts/series.j2 @@ -0,0 +1,40 @@ +# GCE Machine Type Selection +# This file is auto-generated. Do not edit manually. +# Generated by: terraform/gce/scripts/gen_kconfig_machine + +choice + prompt "GCE Machine Family" + default {{ default_series_config }} + help + Select the family of platforms to choose from below. + + Machine types are organized by series, which combines the + generation (e.g., n2, c3) with the workload type (e.g., + standard, highcpu, highmem). + + Machine type availability varies by region and zone. You can + verify available types for your zone using: + + gcloud compute machine-types list --zones= + + For detailed information about GCE machine families: + + https://cloud.google.com/compute/docs/machine-types + +{% for series in series_list %} +config TERRAFORM_GCE_MACHINE_FAMILY_{{ series.series_name.upper().replace('-', '_') }} + bool "{{ series.description }}" +{% if series.architecture == 'arm64' %} + depends on TARGET_ARCH_ARM64 +{% else %} + depends on TARGET_ARCH_X86_64 +{% endif %} + help + {{ series.help_text }} + + This series contains {{ series.type_count }} machine type{{ 's' if series.type_count > 1 else '' }}: + - vCPUs: {{ series.min_vcpus|default(0)|int }}-{{ series.max_vcpus|default(0)|int }} + - Memory: {{ series.min_memory_gb|default(0)|round(1) }}-{{ series.max_memory_gb|default(0)|round(1) }}GB + +{% endfor %} +endchoice From 3fb83deaaf027d605a22f2de84c183842823feb9 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2025 17:44:34 -0500 Subject: [PATCH 7/8] terraform/gce: Generate Kconfig.image dynamically Similar to commit dab6b487bfae for OCI, add a Python script to dynamically generate Linux OS image Kconfig configuration by querying the Google Compute API for available Linux distributors and their releases. Usage: cd terraform/gce/scripts ./gen_kconfig_image > ../kconfigs/Kconfig.image ./gen_kconfig_image --publishers ./gen_kconfig_image debian --format raw The new script follows the same patterns as the AWS, Azure, and OCI scripts but uses the GCE REST API directly with google-auth and requests (as the existing gce_common.py module does) for better distribution package availability. Generated-by: Claude AI Signed-off-by: Chuck Lever --- terraform/gce/scripts/gce_common.py | 140 ++++ terraform/gce/scripts/gen_kconfig_image | 631 ++++++++++++++++++ terraform/gce/scripts/image_distributions.j2 | 21 + terraform/gce/scripts/image_publisher.j2 | 75 +++ .../gce/scripts/publisher_definitions.yml | 123 ++++ 5 files changed, 990 insertions(+) create mode 100755 terraform/gce/scripts/gen_kconfig_image create mode 100644 terraform/gce/scripts/image_distributions.j2 create mode 100644 terraform/gce/scripts/image_publisher.j2 create mode 100644 terraform/gce/scripts/publisher_definitions.yml diff --git a/terraform/gce/scripts/gce_common.py b/terraform/gce/scripts/gce_common.py index c115aaafa..ace08933c 100644 --- a/terraform/gce/scripts/gce_common.py +++ b/terraform/gce/scripts/gce_common.py @@ -444,3 +444,143 @@ def get_machine_type_kconfig_name(machine_type: str) -> str: str: Kconfig constant name (e.g., 'N2_STANDARD_4', 'E2_MICRO') """ return machine_type.upper().replace("-", "_") + + +def list_images( + session: requests.Session, image_project: str, quiet: bool = False +) -> list[dict]: + """ + List all images from a GCE image project using the REST API. + + GCE public images are organized by project. Each Linux distribution + has its own image project (e.g., 'debian-cloud', 'ubuntu-os-cloud'). + + Args: + session: Authenticated requests session + image_project: GCE image project (e.g., 'debian-cloud') + quiet: Suppress debug messages + + Returns: + list: List of image dictionaries from the API + """ + url = f"{GCE_COMPUTE_API}/projects/{image_project}/global/images" + # Request only fields needed for Kconfig generation to reduce network traffic + params = { + "fields": "items(name,family,architecture,deprecated,creationTimestamp)," + "nextPageToken" + } + all_images = [] + + while True: + response = session.get(url, params=params, timeout=GCE_API_TIMEOUT) + if response.status_code == 403: + if not quiet: + print( + f" Warning: Access denied for project {image_project}", + file=sys.stderr, + ) + return [] + elif response.status_code == 404: + if not quiet: + print( + f" Warning: Project {image_project} not found", + file=sys.stderr, + ) + return [] + response.raise_for_status() + + data = response.json() + all_images.extend(data.get("items", [])) + + # Handle pagination + next_page_token = data.get("nextPageToken") + if not next_page_token: + break + params["pageToken"] = next_page_token + + return all_images + + +def get_image_families( + session: requests.Session, image_project: str, quiet: bool = False +) -> dict[str, dict]: + """ + Get image families from a GCE image project. + + Image families group related images together. The latest non-deprecated + image in a family is used when specifying a family instead of a specific + image. This function returns information about each family including + the latest image details. + + Args: + session: Authenticated requests session + image_project: GCE image project (e.g., 'debian-cloud') + quiet: Suppress debug messages + + Returns: + dict: Dictionary mapping family names to family information: + { + 'family_name': { + 'latest_image': str, # Name of latest image + 'architecture': str, # 'X86_64' or 'ARM64' + 'deprecated': bool, # True if family is deprecated + 'creation_timestamp': str, + } + } + """ + images = list_images(session, image_project, quiet) + + # Group images by family and find the latest non-deprecated image + families = {} + + for image in images: + family = image.get("family") + if not family: + continue + + # Check if this image is deprecated + deprecated_state = image.get("deprecated", {}) + is_deprecated = deprecated_state.get("state") == "DEPRECATED" + + # Get architecture (default to X86_64 if not specified) + arch = image.get("architecture", "X86_64") + + creation_timestamp = image.get("creationTimestamp", "") + + # Track family information + if family not in families: + families[family] = { + "latest_image": image.get("name"), + "architecture": arch, + "deprecated": is_deprecated, + "creation_timestamp": creation_timestamp, + } + else: + # Update if this image is better: prefer non-deprecated, then newer + existing = families[family] + existing_deprecated = existing["deprecated"] + + # Determine if we should replace the existing entry: + # 1. Current is non-deprecated, existing is deprecated -> replace + # 2. Both have same deprecation status -> replace if newer + # 3. Current is deprecated, existing is non-deprecated -> keep existing + should_replace = False + if not is_deprecated and existing_deprecated: + # Non-deprecated beats deprecated regardless of timestamp + should_replace = True + elif is_deprecated == existing_deprecated: + # Same deprecation status: compare timestamps. + # ISO 8601 timestamps from GCE sort correctly as strings. + if creation_timestamp > existing["creation_timestamp"]: + should_replace = True + # else: current is deprecated, existing is not -> keep existing + + if should_replace: + families[family] = { + "latest_image": image.get("name"), + "architecture": arch, + "deprecated": is_deprecated, + "creation_timestamp": creation_timestamp, + } + + return families diff --git a/terraform/gce/scripts/gen_kconfig_image b/terraform/gce/scripts/gen_kconfig_image new file mode 100755 index 000000000..da3bb0b4b --- /dev/null +++ b/terraform/gce/scripts/gen_kconfig_image @@ -0,0 +1,631 @@ +#!/usr/bin/env python3 +# ex: set filetype=python: + +""" +Retrieve OS image information from GCE. Use it to construct the "images" +Kconfig menu. + +GCE images are OS templates that can be used to launch compute instances. +This script queries the GCE API to discover available image families and +generates Kconfig menu entries for them. + +Publisher Definitions: + Publisher definitions (e.g., "Debian", "Red Hat") are maintained + in the publisher_definitions.yml file in the same directory as this + script. This makes it easier to update publisher information when + Google adds new distributions or when you want to customize display + names and priorities. + + To update publisher definitions: + 1. Edit terraform/gce/scripts/publisher_definitions.yml + 2. Add or modify entries following the existing format + 3. Run this script to regenerate Kconfig.image + + The YAML file contains detailed instructions for how to add new + publisher definitions. + +Image Discovery: + This script queries each publisher's image project (e.g., debian-cloud, + ubuntu-os-cloud) to discover available image families. Image families + group related images together - when you specify a family, GCE uses + the latest non-deprecated image in that family. + +Usage: + # Generate images Kconfig + ./gen_kconfig_image > ../kconfigs/Kconfig.image + + # List all available publishers + ./gen_kconfig_image --publishers + + # Get details for a specific publisher + ./gen_kconfig_image debian +""" + +from __future__ import annotations + +import sys +import argparse +import re +from collections import defaultdict +from concurrent.futures import ThreadPoolExecutor, as_completed +from typing import Any, Optional + +import requests + +from gce_common import ( + GceNotConfiguredError, + get_jinja2_environment, + load_yaml_config, + get_image_families, + require_gce_credentials, +) + + +def get_known_publishers() -> dict[str, Any]: + """ + Get dictionary of known OS image publishers in GCE. + + Publisher definitions are loaded from publisher_definitions.yml to make + it easier to update when Google adds new Linux distributions or when you + want to customize publisher priorities and naming. + + Returns: + dict: Dictionary mapping publisher keys to publisher information + """ + publishers = load_yaml_config("publisher_definitions.yml", quiet=True) + if not publishers: + print( + "Warning: publisher_definitions.yml not found or empty. " + "Using fallback publisher list.", + file=sys.stderr, + ) + return get_fallback_publishers() + + return publishers + + +def get_fallback_publishers() -> dict[str, Any]: + """ + Get minimal fallback set of known GCE image publishers. + + This is used when publisher_definitions.yml is not available. + + Returns: + dict: Dictionary of publisher information + """ + return { + "debian": { + "project_id": "debian-cloud", + "publisher_name": "Debian", + "description": "Debian", + "priority": 30, + "default_disk_size": 10, + "family_patterns": ["debian-.*"], + }, + "centos": { + "project_id": "centos-cloud", + "publisher_name": "CentOS", + "description": "CentOS", + "priority": 20, + "default_disk_size": 20, + "family_patterns": ["centos-.*"], + }, + } + + +def classify_family( + family_name: str, publisher_key: str, publisher_info: dict[str, Any], arch: str +) -> tuple[Optional[str], Optional[str]]: + """ + Classify an image family into a version key and friendly name. + + Args: + family_name (str): Image family name (e.g., 'debian-12', 'rhel-9') + publisher_key (str): Publisher key (e.g., 'debian', 'redhat') + publisher_info (dict): Publisher information from definitions + arch (str): Architecture ('X86_64' or 'ARM64') + + Returns: + tuple: (version_key, friendly_name) or (None, None) if not classifiable + """ + family_lower = family_name.lower() + description = publisher_info.get("description", publisher_key.title()) + + # Normalize architecture suffix + arch_suffix = "_ARM64" if arch == "ARM64" else "_X86_64" + arch_display = "(arm64)" if arch == "ARM64" else "(x86)" + + # Extract version from family name based on publisher + version = None + version_display = None + + if publisher_key == "debian": + # debian-11, debian-12, debian-12-arm64 + match = re.match(r"debian-(\d+)(?:-arm64)?$", family_lower) + if match: + version = match.group(1) + version_display = version + + elif publisher_key == "centos": + # centos-stream-9, centos-stream-9-arm64 + match = re.match(r"centos-stream-(\d+)(?:-arm64)?$", family_lower) + if match: + version = f"STREAM_{match.group(1)}" + version_display = f"Stream {match.group(1)}" + else: + # centos-7 (legacy) + match = re.match(r"centos-(\d+)$", family_lower) + if match: + version = match.group(1) + version_display = match.group(1) + + elif publisher_key == "ubuntu": + # Skip minimal and generic 'minimal' family + if family_lower == "minimal": + return (None, None) + + # ubuntu-2404-lts-amd64, ubuntu-2404-lts-arm64 + match = re.match( + r"ubuntu-(?:minimal-)?(\d{2})(\d{2})-lts(?:-(?:amd64|arm64))?$", + family_lower, + ) + if match: + major = match.group(1) + minor = match.group(2) + version = f"{major}_{minor}_LTS" + version_display = f"{major}.{minor} LTS" + else: + # ubuntu-2410-amd64, ubuntu-2410-arm64 (non-LTS newer format) + match = re.match( + r"ubuntu-(?:minimal-)?(\d{2})(\d{2})(?:-(?:amd64|arm64))?$", + family_lower, + ) + if match: + major = match.group(1) + minor = match.group(2) + version = f"{major}_{minor}" + version_display = f"{major}.{minor}" + # Check for minimal variant + if "minimal" in family_lower and version: + version = f"MINIMAL_{version}" + version_display = f"Minimal {version_display}" + + elif publisher_key == "redhat": + # rhel-9, rhel-8, rhel-9-arm64 + match = re.match(r"rhel-(\d+)(?:-arm64)?$", family_lower) + if match: + version = match.group(1) + version_display = version + + elif publisher_key == "rocky": + # rocky-linux-9, rocky-linux-9-arm64, rocky-linux-9-optimized-gcp + match = re.match( + r"rocky-linux-(\d+)(?:-optimized-gcp)?(?:-arm64)?$", family_lower + ) + if match: + version = match.group(1) + version_display = match.group(1) + if "optimized-gcp" in family_lower: + version = f"{version}_OPTIMIZED" + version_display = f"{version_display} (GCP Optimized)" + + elif publisher_key == "almalinux": + # almalinux-9, almalinux-9-arm64 + match = re.match(r"almalinux-(\d+)(?:-arm64)?$", family_lower) + if match: + version = match.group(1) + version_display = match.group(1) + + elif publisher_key == "fedora": + # fedora-cloud-42-x86-64, fedora-cloud-42-aarch64 (newer format) + match = re.match(r"fedora-cloud-(\d+)-(?:x86-64|aarch64)$", family_lower) + if match: + version = f"CLOUD_{match.group(1)}" + version_display = f"Cloud {match.group(1)}" + else: + # fedora-cloud-40 (older format without arch suffix) + match = re.match(r"fedora-cloud-(\d+)$", family_lower) + if match: + version = f"CLOUD_{match.group(1)}" + version_display = f"Cloud {match.group(1)}" + else: + # fedora-cloud-rawhide-x86-64, fedora-cloud-eln-aarch64 + match = re.match( + r"fedora-cloud-(rawhide|eln)-(?:x86-64|aarch64)$", family_lower + ) + if match: + channel = match.group(1).upper() + version = f"CLOUD_{channel}" + version_display = f"Cloud {match.group(1).title()}" + + elif publisher_key == "opensuse": + # opensuse-leap, opensuse-leap-arm64 (no version number in family) + match = re.match(r"opensuse-leap(?:-arm64)?$", family_lower) + if match: + version = "LEAP" + version_display = "Leap" + + elif publisher_key == "suse": + # sles-15-sp6, sles-15-sp6-arm64, sles-16-0-arm64, sles-16-0-x86-64 + match = re.match(r"sles-(\d+)-sp(\d+)(?:-(?:arm64|x86-64))?$", family_lower) + if match: + major = match.group(1) + sp = match.group(2) + version = f"{major}_SP{sp}" + version_display = f"{major} SP{sp}" + else: + # sles-16-0-arm64, sles-16-0-x86-64 (new versioning) + match = re.match(r"sles-(\d+)-(\d+)(?:-(?:arm64|x86-64))?$", family_lower) + if match: + major = match.group(1) + minor = match.group(2) + version = f"{major}_{minor}" + version_display = f"{major}.{minor}" + else: + # sles-15, sles-12 (base versions) + match = re.match(r"sles-(\d+)(?:-arm64)?$", family_lower) + if match: + version = match.group(1) + version_display = match.group(1) + + elif publisher_key == "oracle": + # oracle-linux-9, oracle-linux-8, oracle-linux-9-arm64 + match = re.match(r"oracle-linux-(\d+)(?:-arm64)?$", family_lower) + if match: + version = match.group(1) + version_display = match.group(1) + + if not version: + return (None, None) + + version_key = f"{publisher_key.upper()}_{version}{arch_suffix}" + friendly_name = f"{description} {version_display} {arch_display}" + + return (version_key, friendly_name) + + +def organize_images_by_publisher( + session: requests.Session, publishers: dict[str, Any], quiet: bool = False +) -> dict[str, dict[str, dict[str, Any]]]: + """ + Organize GCE images by publisher and version. + + Args: + session: Authenticated requests session + publishers (dict): Dictionary of publisher information + quiet (bool): Suppress debug messages + + Returns: + dict: Organized structure {publisher: {version_key: {family, arch, ...}}} + """ + organized = defaultdict(lambda: defaultdict(dict)) + + def process_publisher( + publisher_key: str, publisher_info: dict[str, Any] + ) -> tuple[str, dict[str, dict[str, Any]]]: + """Process a single publisher and return results.""" + project_id = publisher_info.get("project_id") + if not project_id: + return publisher_key, {} + + family_patterns = publisher_info.get("family_patterns", []) + family_regexes = ( + [re.compile(p) for p in family_patterns] if family_patterns else [] + ) + + families = get_image_families(session, project_id, quiet=True) + + publisher_versions = {} + for family_name, family_info in families.items(): + # Skip families that don't match any pattern (if patterns are defined) + if family_regexes and not any( + regex.match(family_name) for regex in family_regexes + ): + continue + + arch = family_info.get("architecture", "X86_64") + version_key, friendly_name = classify_family( + family_name, publisher_key, publisher_info, arch + ) + + if not version_key: + continue + + # Store image family information + publisher_versions[version_key] = { + "friendly_name": friendly_name, + "family": family_name, + "architecture": arch, + "deprecated": family_info.get("deprecated", False), + } + + return publisher_key, publisher_versions + + # Process publishers in parallel for better performance + with ThreadPoolExecutor(max_workers=10) as executor: + futures = { + executor.submit(process_publisher, pub_key, pub_info): pub_key + for pub_key, pub_info in publishers.items() + } + + for future in as_completed(futures): + publisher_key = futures[future] + try: + pub_key, versions = future.result() + if versions: + organized[pub_key] = versions + if not quiet: + print( + f"Publisher '{pub_key}': {len(versions)} image families", + file=sys.stderr, + ) + except Exception as exc: + if not quiet: + print( + f"Error processing {publisher_key}: {exc}", + file=sys.stderr, + ) + + return organized + + +def output_images_kconfig( + organized_images: dict[str, dict[str, dict[str, Any]]], publishers: dict[str, Any] +) -> None: + """ + Output images menu in Kconfig format. + + Args: + organized_images (dict): Organized images from organize_images_by_publisher() + publishers (dict): Dictionary of all publishers + """ + print("# This file was auto-generated by gen_kconfig_image") + print("#") + print("# To regenerate: cd terraform/gce/scripts && ./gen_kconfig_image") + print() + + environment = get_jinja2_environment() + + # Sort publishers by priority for consistent ordering + sorted_publishers = sorted( + [(k, v) for k, v in publishers.items() if k in organized_images], + key=lambda x: (x[1].get("priority", 100), x[0]), + ) + + # Build publisher names dict for the distributions template + publisher_names = { + k: v.get("publisher_name", k.title()) for k, v in publishers.items() + } + + # Output the top-level distribution choice menu + template = environment.get_template("image_distributions.j2") + print( + template.render( + publishers=[pub[0] for pub in sorted_publishers], + publisher_names=publisher_names, + ) + ) + print() + + def version_sort_key( + version_item: tuple[str, dict[str, Any]] + ) -> tuple[int, int, int]: + """ + Extract numeric version from version_key for proper chronological sorting. + + Version keys are like: DEBIAN_12_X86_64, RHEL_9_ARM64 + Sort by numeric version (oldest to newest), not alphabetic. + """ + version_key, version_data = version_item + parts = version_key.split("_") + + # Remove publisher prefix and architecture suffix + # Could be: [major] or [major, minor] or [STREAM, major] + version_parts = parts[1:-1] # Remove first (publisher) and last (arch) + + major = 0 + minor = 0 + + if len(version_parts) >= 1: + # Handle special prefixes like STREAM, LEAP, CLOUD + first_part = version_parts[0] + if first_part in ("STREAM", "LEAP", "CLOUD", "COREOS", "MINIMAL"): + if len(version_parts) >= 2: + try: + major = int(version_parts[1]) + if len(version_parts) >= 3: + try: + minor = int(version_parts[2]) + except ValueError: + pass + except ValueError: + pass + else: + try: + major = int(first_part) + if len(version_parts) >= 2: + try: + minor = int(version_parts[1]) + except ValueError: + pass + except ValueError: + pass + + # Architecture preference: X86_64, ARM64 for consistent ordering + arch_order = {"X86_64": 0, "ARM64": 1} + arch = parts[-1] if parts else "X86_64" + arch_priority = arch_order.get(arch, 99) + + return (major, minor, arch_priority) + + # Output each publisher's images + template = environment.get_template("image_publisher.j2") + for publisher_key, publisher_info in sorted_publishers: + versions = organized_images.get(publisher_key, {}) + + # Sort versions numerically (oldest to newest) + sorted_versions = sorted(versions.items(), key=version_sort_key) + + # Check if there are any ARM64 images + has_arm64 = any("ARM64" in v[0] for v in sorted_versions) + + print( + template.render( + publisher_key=publisher_key, + publisher_name=publisher_info.get("publisher_name", publisher_key), + publisher_description=publisher_info.get("description", publisher_key), + project_id=publisher_info.get("project_id", ""), + default_disk_size=publisher_info.get("default_disk_size", 20), + versions=sorted_versions, + has_arm64=has_arm64, + ) + ) + print() + + +def output_publishers_raw(quiet: bool = False) -> None: + """Output available publishers in table format.""" + publishers = get_known_publishers() + + if not quiet: + print(f"Known OS image publishers ({len(publishers)}):\n") + + print(f"{'Publisher Key':<15} {'Project ID':<25} {'Description':<30}") + print("-" * 75) + + for key, info in sorted( + publishers.items(), key=lambda x: x[1].get("priority", 100) + ): + print( + f"{key:<15} " + f"{info.get('project_id', ''):<25} " + f"{info.get('description', ''):<30}" + ) + + +def output_publisher_raw( + publisher_key: str, + organized_images: dict[str, dict[str, dict[str, Any]]], + quiet: bool = False, +) -> None: + """Output publisher image information in table format.""" + publishers = get_known_publishers() + publisher_info = publishers.get(publisher_key, {}) + + if not quiet: + print(f"Images for {publisher_info.get('publisher_name', publisher_key)}") + print(f"Project: {publisher_info.get('project_id', '')}") + print(f"Description: {publisher_info.get('description', '')}\n") + + versions = organized_images.get(publisher_key, {}) + if not versions: + print(f"No images found for publisher '{publisher_key}'.") + return + + print(f"{'Version Key':<40} {'Family':<30} {'Arch':<10}") + print("-" * 85) + + for version_key, version_info in sorted(versions.items()): + print( + f"{version_key:<40} " + f"{version_info['family']:<30} " + f"{version_info['architecture']:<10}" + ) + + +def parse_arguments() -> argparse.Namespace: + """Parse command line arguments.""" + parser = argparse.ArgumentParser( + description="Get GCE OS image information and generate Kconfig", + formatter_class=argparse.RawDescriptionHelpFormatter, + epilog=""" +Examples: + # Generate Kconfig + python %(prog)s > ../kconfigs/Kconfig.image + + # List available publishers + python %(prog)s --publishers + + # Get details for a specific publisher + python %(prog)s debian --format raw + """, + ) + parser.add_argument( + "publisher_key", nargs="?", help="Publisher key (e.g., debian, redhat)" + ) + + parser.add_argument( + "--publishers", action="store_true", help="List all known publishers" + ) + parser.add_argument( + "--format", + "-f", + choices=["raw", "kconfig"], + default="kconfig", + help="Output format (default: kconfig)", + ) + parser.add_argument( + "--quiet", "-q", action="store_true", help="Suppress informational messages" + ) + return parser.parse_args() + + +def main() -> None: + """Main function to run the program.""" + args = parse_arguments() + + if args.publishers: + output_publishers_raw(args.quiet) + return + + publishers = get_known_publishers() + + # Filter to specific publisher if requested + if args.publisher_key: + if args.publisher_key not in publishers: + print( + f"Error: Unknown publisher '{args.publisher_key}'. " + f"Use --publishers to list available publishers.", + file=sys.stderr, + ) + sys.exit(1) + publishers = {args.publisher_key: publishers[args.publisher_key]} + + # Allow make dynconfig to succeed without GCE credentials + try: + session, project = require_gce_credentials() + except GceNotConfiguredError: + if not args.quiet: + print("GCE not configured - skipping (optional)", file=sys.stderr) + sys.exit(0) + + if not args.quiet: + print(f"Using project: {project}", file=sys.stderr) + print("Querying image families from GCE...", file=sys.stderr) + + # Organize images + organized_images = organize_images_by_publisher(session, publishers, args.quiet) + + if not organized_images: + print("Error: No images found", file=sys.stderr) + sys.exit(1) + + # Output based on format + if args.publisher_key: + if args.format == "raw": + output_publisher_raw(args.publisher_key, organized_images, args.quiet) + else: + # For single publisher, still output full Kconfig + output_images_kconfig(organized_images, publishers) + else: + if args.format == "kconfig": + output_images_kconfig(organized_images, publishers) + else: + # Raw format for all publishers + for publisher_key in sorted(organized_images.keys()): + output_publisher_raw(publisher_key, organized_images, args.quiet) + print() + + +if __name__ == "__main__": + main() diff --git a/terraform/gce/scripts/image_distributions.j2 b/terraform/gce/scripts/image_distributions.j2 new file mode 100644 index 000000000..18b2e945d --- /dev/null +++ b/terraform/gce/scripts/image_distributions.j2 @@ -0,0 +1,21 @@ +choice + prompt "OS Distributor" +{% if 'debian' in publishers %} + default TERRAFORM_GCE_DISTRO_DEBIAN +{% elif 'centos' in publishers %} + default TERRAFORM_GCE_DISTRO_CENTOS +{% elif 'ubuntu' in publishers %} + default TERRAFORM_GCE_DISTRO_UBUNTU +{% elif publishers %} + default TERRAFORM_GCE_DISTRO_{{ publishers[0] | upper }} +{% endif %} + help + Select the Linux distribution for the OS base image of the + instances to be created. + +{% for publisher_key in publishers %} +config TERRAFORM_GCE_DISTRO_{{ publisher_key | upper }} + bool "{{ publisher_names[publisher_key] }}" + +{% endfor %} +endchoice diff --git a/terraform/gce/scripts/image_publisher.j2 b/terraform/gce/scripts/image_publisher.j2 new file mode 100644 index 000000000..c59e915aa --- /dev/null +++ b/terraform/gce/scripts/image_publisher.j2 @@ -0,0 +1,75 @@ +{# + This template is rendered by gen_kconfig_image script. + + Template variables: + - publisher_key: str (e.g., 'debian', 'redhat') + - publisher_name: str (e.g., 'Debian') + - publisher_description: str (full description) + - project_id: str (GCE project ID, e.g., 'debian-cloud') + - default_disk_size: int (default disk size in GB) + - versions: list of (version_key, version_info) tuples (pre-sorted) + - has_arm64: bool (whether ARM64 images exist for this publisher) +#} +{% macro arch_image_config(arch_name, arch_filter) %} +if TARGET_ARCH_{{ arch_name }} + +{% set ns = namespace(has_valid=false) %} +{% for version_key, version_info in versions %} +{% if arch_filter in version_key and not version_info.get('deprecated') %} +{% set ns.has_valid = true %} +{% endif %} +{% endfor %} +{% if ns.has_valid %} +choice + prompt "OS image to use" +{% set ns = namespace(found_default=false) %} +{% for version_key, version_info in versions | reverse %} +{% if arch_filter in version_key and not version_info.get('deprecated') and not ns.found_default %} + default TERRAFORM_GCE_IMAGE_{{ version_key }} +{% set ns.found_default = true %} +{% endif %} +{% endfor %} + +{% for version_key, version_info in versions %} +{% if arch_filter in version_key %} +config TERRAFORM_GCE_IMAGE_{{ version_key }} + bool "{{ version_info['friendly_name'] }}" +{% if version_info.get('deprecated') %} + help + This image family is deprecated. +{% endif %} + +{% endif %} +{% endfor %} +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml +{% for version_key, version_info in versions %} +{% if arch_filter in version_key %} + default "{{ version_info['family'] }}" if TERRAFORM_GCE_IMAGE_{{ version_key }} +{% endif %} +{% endfor %} + +{% endif %} +endif # TARGET_ARCH_{{ arch_name }} + +{% endmacro %} +if TERRAFORM_GCE_DISTRO_{{ publisher_key | upper }} + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "{{ project_id }}" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default {{ default_disk_size }} + +{{ arch_image_config("X86_64", "X86_64") -}} +{% if has_arm64 %} +{{ arch_image_config("ARM64", "ARM64") -}} +{% endif %} +endif # TERRAFORM_GCE_DISTRO_{{ publisher_key | upper }} diff --git a/terraform/gce/scripts/publisher_definitions.yml b/terraform/gce/scripts/publisher_definitions.yml new file mode 100644 index 000000000..73c3e7687 --- /dev/null +++ b/terraform/gce/scripts/publisher_definitions.yml @@ -0,0 +1,123 @@ +# Publisher definitions for GCE OS images +# +# This file defines the Linux distribution publishers whose images are +# available on Google Compute Engine. Each publisher entry specifies: +# +# - project_id: The GCE image project (e.g., "debian-cloud") +# - publisher_name: Display name for the publisher +# - description: Full description used in Kconfig help text +# - priority: Display order in menus (lower = higher priority) +# - default_disk_size: Default boot disk size in GB for this distribution +# - family_patterns: Regex patterns to match image family names +# +# To add a new publisher: +# 1. Find the GCE image project ID (use `gcloud compute images list`) +# 2. Add an entry with all required fields +# 3. Run gen_kconfig_image to regenerate Kconfig.image +# +# Google Cloud public image documentation: +# https://cloud.google.com/compute/docs/images + +# AlmaLinux - Community-maintained RHEL derivative +almalinux: + project_id: "almalinux-cloud" + publisher_name: "AlmaLinux" + description: "AlmaLinux" + priority: 10 + default_disk_size: 20 + family_patterns: + - "almalinux-.*" + +# CentOS - Red Hat-sponsored community Linux +centos: + project_id: "centos-cloud" + publisher_name: "CentOS" + description: "CentOS" + priority: 20 + default_disk_size: 20 + family_patterns: + - "centos-stream-.*" + - "centos-.*" + +# Debian - Universal operating system +debian: + project_id: "debian-cloud" + publisher_name: "Debian" + description: "Debian" + priority: 30 + default_disk_size: 10 + family_patterns: + - "debian-.*" + +# Fedora - Cutting-edge community Linux +fedora: + project_id: "fedora-cloud" + publisher_name: "Fedora" + description: "Fedora Linux" + priority: 40 + default_disk_size: 20 + family_patterns: + - "fedora-cloud-.*" + - "fedora-.*" + +# openSUSE - Community SUSE distribution +opensuse: + project_id: "opensuse-cloud" + publisher_name: "openSUSE" + description: "openSUSE" + priority: 50 + default_disk_size: 10 + family_patterns: + - "opensuse-leap-.*" + - "opensuse-.*" + +# Oracle Linux - Oracle's enterprise Linux +oracle: + project_id: "oracle-linux-cloud" + publisher_name: "Oracle" + description: "Oracle Linux" + priority: 60 + default_disk_size: 20 + family_patterns: + - "oracle-linux-.*" + +# Red Hat Enterprise Linux - Enterprise Linux distribution +redhat: + project_id: "rhel-cloud" + publisher_name: "Red Hat" + description: "Red Hat Enterprise Linux" + priority: 70 + default_disk_size: 20 + family_patterns: + - "rhel-.*" + +# Rocky Linux - RHEL-compatible community distribution +rocky: + project_id: "rocky-linux-cloud" + publisher_name: "Rocky Linux" + description: "Rocky Linux" + priority: 80 + default_disk_size: 20 + family_patterns: + - "rocky-linux-.*" + +# SUSE Linux Enterprise Server - Enterprise SUSE distribution +suse: + project_id: "suse-cloud" + publisher_name: "SUSE" + description: "SUSE Linux Enterprise Server" + priority: 90 + default_disk_size: 10 + family_patterns: + - "sles-.*" + - "sle-.*" + +# Ubuntu - Popular Debian-based distribution +ubuntu: + project_id: "ubuntu-os-cloud" + publisher_name: "Canonical" + description: "Ubuntu" + priority: 100 + default_disk_size: 10 + family_patterns: + - "ubuntu-.*" From e7a39eb77709d100616c1c926e73fd34e5b73273 Mon Sep 17 00:00:00 2001 From: Chuck Lever Date: Thu, 4 Dec 2025 17:54:59 -0500 Subject: [PATCH 8/8] scripts: Add GCE to generate_cloud_configs.py This change enables dynamic GCE region, image, and machine type discovery and Kconfig generation via "make cloud-config" or "make cloud-config-gce". The generate_gce_kconfig() function runs the existing scripts in terraform/gce/scripts (gen_kconfig_image, gen_kconfig_location, and gen_kconfig_machine) and writes their output to the generated Kconfig files that are now sourced by terraform/gce/Kconfig. Generated-by: Claude AI Signed-off-by: Chuck Lever --- .gitignore | 3 + scripts/dynamic-cloud-kconfig.Makefile | 40 +- scripts/generate_cloud_configs.py | 55 +- terraform/gce/Kconfig | 6 +- terraform/gce/kconfigs/Kconfig.image | 377 --- terraform/gce/kconfigs/Kconfig.image.default | 1075 +++++++ terraform/gce/kconfigs/Kconfig.location | 499 ---- .../gce/kconfigs/Kconfig.location.default | 1452 ++++++++++ terraform/gce/kconfigs/Kconfig.machine | 995 ------- .../gce/kconfigs/Kconfig.machine.default | 2496 +++++++++++++++++ 10 files changed, 5117 insertions(+), 1881 deletions(-) delete mode 100644 terraform/gce/kconfigs/Kconfig.image create mode 100644 terraform/gce/kconfigs/Kconfig.image.default delete mode 100644 terraform/gce/kconfigs/Kconfig.location create mode 100644 terraform/gce/kconfigs/Kconfig.location.default delete mode 100644 terraform/gce/kconfigs/Kconfig.machine create mode 100644 terraform/gce/kconfigs/Kconfig.machine.default diff --git a/.gitignore b/.gitignore index e1f803551..89c2898ed 100644 --- a/.gitignore +++ b/.gitignore @@ -132,6 +132,9 @@ terraform/azure/kconfigs/Kconfig.location.generated terraform/azure/kconfigs/Kconfig.size.generated terraform/azure/scripts/__pycache__/ +terraform/gce/kconfigs/Kconfig.image.generated +terraform/gce/kconfigs/Kconfig.location.generated +terraform/gce/kconfigs/Kconfig.machine.generated terraform/gce/scripts/__pycache__/ terraform/oci/kconfigs/Kconfig.image.generated diff --git a/scripts/dynamic-cloud-kconfig.Makefile b/scripts/dynamic-cloud-kconfig.Makefile index 7fd9e55f0..b34dc7737 100644 --- a/scripts/dynamic-cloud-kconfig.Makefile +++ b/scripts/dynamic-cloud-kconfig.Makefile @@ -43,6 +43,19 @@ AZURE_KCONFIG_SIZE_DEFAULT := $(AZURE_KCONFIG_DIR)/Kconfig.size.default AZURE_KCONFIGS := $(AZURE_KCONFIG_LOCATION) $(AZURE_KCONFIG_SIZE) $(AZURE_KCONFIG_IMAGE) +# GCE dynamic configuration +GCE_KCONFIG_DIR := terraform/gce/kconfigs +GCE_KCONFIG_IMAGE := $(GCE_KCONFIG_DIR)/Kconfig.image.generated +GCE_KCONFIG_LOCATION := $(GCE_KCONFIG_DIR)/Kconfig.location.generated +GCE_KCONFIG_MACHINE := $(GCE_KCONFIG_DIR)/Kconfig.machine.generated + +# GCE default files (tracked in git, provide sensible defaults) +GCE_KCONFIG_IMAGE_DEFAULT := $(GCE_KCONFIG_DIR)/Kconfig.image.default +GCE_KCONFIG_LOCATION_DEFAULT := $(GCE_KCONFIG_DIR)/Kconfig.location.default +GCE_KCONFIG_MACHINE_DEFAULT := $(GCE_KCONFIG_DIR)/Kconfig.machine.default + +GCE_KCONFIGS := $(GCE_KCONFIG_IMAGE) $(GCE_KCONFIG_LOCATION) $(GCE_KCONFIG_MACHINE) + # OCI dynamic configuration OCI_KCONFIG_DIR := terraform/oci/kconfigs OCI_KCONFIG_IMAGE := $(OCI_KCONFIG_DIR)/Kconfig.image.generated @@ -70,7 +83,7 @@ DATACRUNCH_KCONFIG_LOCATION_DEFAULT := $(DATACRUNCH_KCONFIG_DIR)/Kconfig.locatio DATACRUNCH_KCONFIGS := $(DATACRUNCH_KCONFIG_COMPUTE) $(DATACRUNCH_KCONFIG_IMAGES) $(DATACRUNCH_KCONFIG_LOCATION) # Add generated files to mrproper clean list -KDEVOPS_MRPROPER += $(LAMBDALABS_KCONFIGS) $(AWS_KCONFIGS) $(AZURE_KCONFIGS) $(OCI_KCONFIGS) $(DATACRUNCH_KCONFIGS) +KDEVOPS_MRPROPER += $(LAMBDALABS_KCONFIGS) $(AWS_KCONFIGS) $(AZURE_KCONFIGS) $(GCE_KCONFIGS) $(OCI_KCONFIGS) $(DATACRUNCH_KCONFIGS) # Ensure Lambda Labs generated files exist with sensible defaults # Copies from .default files if .generated files don't exist @@ -93,6 +106,13 @@ dynamic_azure_kconfig_touch: $(Q)test -f $(AZURE_KCONFIG_LOCATION) || cp $(AZURE_KCONFIG_LOCATION_DEFAULT) $(AZURE_KCONFIG_LOCATION) $(Q)test -f $(AZURE_KCONFIG_SIZE) || cp $(AZURE_KCONFIG_SIZE_DEFAULT) $(AZURE_KCONFIG_SIZE) +# Ensure GCE generated files exist with sensible defaults +# Copies from .default files if .generated files don't exist +dynamic_gce_kconfig_touch: + $(Q)test -f $(GCE_KCONFIG_IMAGE) || cp $(GCE_KCONFIG_IMAGE_DEFAULT) $(GCE_KCONFIG_IMAGE) + $(Q)test -f $(GCE_KCONFIG_LOCATION) || cp $(GCE_KCONFIG_LOCATION_DEFAULT) $(GCE_KCONFIG_LOCATION) + $(Q)test -f $(GCE_KCONFIG_MACHINE) || cp $(GCE_KCONFIG_MACHINE_DEFAULT) $(GCE_KCONFIG_MACHINE) + # Ensure OCI generated files exist with sensible defaults # Copies from .default files if .generated files don't exist dynamic_oci_kconfig_touch: @@ -107,11 +127,11 @@ dynamic_datacrunch_kconfig_touch: $(Q)test -f $(DATACRUNCH_KCONFIG_IMAGES) || cp $(DATACRUNCH_KCONFIG_IMAGES_DEFAULT) $(DATACRUNCH_KCONFIG_IMAGES) $(Q)test -f $(DATACRUNCH_KCONFIG_LOCATION) || cp $(DATACRUNCH_KCONFIG_LOCATION_DEFAULT) $(DATACRUNCH_KCONFIG_LOCATION) -DYNAMIC_KCONFIG += dynamic_lambdalabs_kconfig_touch dynamic_aws_kconfig_touch dynamic_azure_kconfig_touch dynamic_oci_kconfig_touch dynamic_datacrunch_kconfig_touch +DYNAMIC_KCONFIG += dynamic_lambdalabs_kconfig_touch dynamic_aws_kconfig_touch dynamic_azure_kconfig_touch dynamic_gce_kconfig_touch dynamic_oci_kconfig_touch dynamic_datacrunch_kconfig_touch # User-facing target to populate cloud kconfigs with defaults # This is called automatically before menuconfig, but can be run manually -default-cloud-kconfigs: dynamic_lambdalabs_kconfig_touch dynamic_aws_kconfig_touch dynamic_azure_kconfig_touch dynamic_oci_kconfig_touch dynamic_datacrunch_kconfig_touch +default-cloud-kconfigs: dynamic_lambdalabs_kconfig_touch dynamic_aws_kconfig_touch dynamic_azure_kconfig_touch dynamic_gce_kconfig_touch dynamic_oci_kconfig_touch dynamic_datacrunch_kconfig_touch # Lambda Labs targets use --provider argument for efficiency cloud-config-lambdalabs: @@ -125,6 +145,10 @@ cloud-config-aws: cloud-config-azure: $(Q)python3 scripts/generate_cloud_configs.py --provider azure +# GCE targets use --provider argument for efficiency +cloud-config-gce: + $(Q)python3 scripts/generate_cloud_configs.py --provider gce + # OCI targets use --provider argument for efficiency cloud-config-oci: $(Q)python3 scripts/generate_cloud_configs.py --provider oci @@ -145,6 +169,10 @@ clean-cloud-config-aws: clean-cloud-config-azure: $(Q)rm -f $(AZURE_KCONFIGS) +# Clean GCE generated files +clean-cloud-config-gce: + $(Q)rm -f $(GCE_KCONFIGS) + # Clean OCI generated files clean-cloud-config-oci: $(Q)rm -f $(OCI_KCONFIGS) @@ -153,7 +181,7 @@ clean-cloud-config-oci: clean-cloud-config-datacrunch: $(Q)rm -f $(DATACRUNCH_KCONFIGS) -DYNAMIC_CLOUD_KCONFIG += cloud-config-lambdalabs cloud-config-aws cloud-config-azure cloud-config-oci cloud-config-datacrunch +DYNAMIC_CLOUD_KCONFIG += cloud-config-lambdalabs cloud-config-aws cloud-config-azure cloud-config-gce cloud-config-oci cloud-config-datacrunch cloud-config-help: @echo "Cloud-specific dynamic kconfig targets:" @@ -162,6 +190,7 @@ cloud-config-help: @echo "cloud-config-lambdalabs - generates Lambda Labs dynamic kconfig content" @echo "cloud-config-aws - generates AWS dynamic kconfig content" @echo "cloud-config-azure - generates Azure dynamic kconfig content" + @echo "cloud-config-gce - generates GCE dynamic kconfig content" @echo "cloud-config-oci - generates OCI dynamic kconfig content" @echo "cloud-config-datacrunch - generates DataCrunch dynamic kconfig content" @echo "clean-cloud-config - removes all generated cloud kconfig files" @@ -172,7 +201,7 @@ HELP_TARGETS += cloud-config-help cloud-config: $(Q)python3 scripts/generate_cloud_configs.py -clean-cloud-config: clean-cloud-config-lambdalabs clean-cloud-config-aws clean-cloud-config-azure clean-cloud-config-oci clean-cloud-config-datacrunch +clean-cloud-config: clean-cloud-config-lambdalabs clean-cloud-config-aws clean-cloud-config-azure clean-cloud-config-gce clean-cloud-config-oci clean-cloud-config-datacrunch $(Q)echo "Cleaned all cloud provider dynamic Kconfig files." cloud-list-all: @@ -182,6 +211,7 @@ cloud-list-all: PHONY += cloud-config clean-cloud-config cloud-config-help cloud-list-all default-cloud-kconfigs PHONY += cloud-config-aws clean-cloud-config-aws PHONY += cloud-config-azure clean-cloud-config-azure +PHONY += cloud-config-gce clean-cloud-config-gce PHONY += cloud-config-datacrunch clean-cloud-config-datacrunch PHONY += cloud-config-lambdalabs clean-cloud-config-lambdalabs PHONY += cloud-config-oci clean-cloud-config-oci diff --git a/scripts/generate_cloud_configs.py b/scripts/generate_cloud_configs.py index 4e1e908c6..38cc9de7f 100755 --- a/scripts/generate_cloud_configs.py +++ b/scripts/generate_cloud_configs.py @@ -193,6 +193,52 @@ def generate_azure_kconfig() -> bool: return all_success +def generate_gce_kconfig() -> bool: + """ + Generate GCE Kconfig files. + Returns True on success, False on failure. + """ + script_dir = os.path.dirname(os.path.abspath(__file__)) + project_root = os.path.dirname(script_dir) + gce_scripts_dir = os.path.join(project_root, "terraform", "gce", "scripts") + gce_kconfigs_dir = os.path.join(project_root, "terraform", "gce", "kconfigs") + + # Define the script-to-output mapping + scripts_to_run = [ + ("gen_kconfig_image", "Kconfig.image.generated"), + ("gen_kconfig_location", "Kconfig.location.generated"), + ("gen_kconfig_machine", "Kconfig.machine.generated"), + ] + + all_success = True + + for script_name, kconfig_file in scripts_to_run: + script_path = os.path.join(gce_scripts_dir, script_name) + output_path = os.path.join(gce_kconfigs_dir, kconfig_file) + + # Run the script and capture its output + result = subprocess.run( + [script_path], + capture_output=True, + text=True, + check=False, + ) + + if result.returncode == 0: + # Write the output to the corresponding Kconfig file + try: + with open(output_path, "w") as f: + f.write(result.stdout) + except IOError as e: + print(f"Error writing {kconfig_file}: {e}", file=sys.stderr) + all_success = False + else: + print(f"Error running {script_name}: {result.stderr}", file=sys.stderr) + all_success = False + + return all_success + + def generate_oci_kconfig() -> bool: """ Generate OCI Kconfig files. @@ -278,8 +324,13 @@ def process_azure(): def process_gce(): - """Process GCE configuration (placeholder).""" - print("⚠ GCE: Dynamic configuration not yet implemented") + """Process GCE configuration.""" + kconfig_generated = generate_gce_kconfig() + if kconfig_generated: + print("✓ GCE: Kconfig files generated successfully") + else: + print("⚠ GCE: Failed to generate Kconfig files - using defaults") + print() def process_oci(): diff --git a/terraform/gce/Kconfig b/terraform/gce/Kconfig index 7c4c6141b..a478f50c9 100644 --- a/terraform/gce/Kconfig +++ b/terraform/gce/Kconfig @@ -1,13 +1,13 @@ if TERRAFORM_GCE menu "Resource Location" -source "terraform/gce/kconfigs/Kconfig.location" +source "terraform/gce/kconfigs/Kconfig.location.generated" endmenu menu "Compute" comment "Machine selection" -source "terraform/gce/kconfigs/Kconfig.machine" +source "terraform/gce/kconfigs/Kconfig.machine.generated" comment "OS image selection" -source "terraform/gce/kconfigs/Kconfig.image" +source "terraform/gce/kconfigs/Kconfig.image.generated" endmenu menu "Storage" source "terraform/gce/kconfigs/Kconfig.storage" diff --git a/terraform/gce/kconfigs/Kconfig.image b/terraform/gce/kconfigs/Kconfig.image deleted file mode 100644 index a4487a045..000000000 --- a/terraform/gce/kconfigs/Kconfig.image +++ /dev/null @@ -1,377 +0,0 @@ -choice - prompt "OS Distributor" - default TERRAFORM_GCE_DISTRO_DEBIAN - help - Select the Linux distribution for the OS base image of the - instances to be created. - -config TERRAFORM_GCE_DISTRO_CENTOS - bool "CentOS" - -config TERRAFORM_GCE_DISTRO_DEBIAN - bool "Debian" - -config TERRAFORM_GCE_DISTRO_OL - bool "Oracle Linux" - -config TERRAFORM_GCE_DISTRO_OPENSUSE - bool "OpenSUSE" - -config TERRAFORM_GCE_DISTRO_RHEL - bool "Red Hat Enterprise Linux" - -config TERRAFORM_GCE_DISTRO_ROCKY - bool "Rocky Linux" - -config TERRAFORM_GCE_DISTRO_SLES - bool "SUSE Enterprise Linux Server" - -endchoice - -if TERRAFORM_GCE_DISTRO_CENTOS - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "centos-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 - -config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 - bool "CentOS Stream 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "centos-stream-9" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 - -config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 - bool "CentOS Stream 9 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "centos-stream-9-arm64" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_CENTOS - -if TERRAFORM_GCE_DISTRO_DEBIAN - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "debian-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 10 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 - -config TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 - bool "Debian-11 Bullseye (x86)" - -config TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 - bool "Debian-12 Bookworm (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "debian-11" if TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 - default "debian-12" if TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 - -config TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 - bool "Debian-12 Bookworm (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "debian-12-arm64" if TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_DEBIAN - -if TERRAFORM_GCE_DISTRO_OPENSUSE - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "opensuse-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 10 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 - -config TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 - bool "OpenLeap 15.5 (x86)" - -config TERRAFORM_GCE_IMAGE_OPENLEAP_15_6_X86_64 - bool "OpenLeap 15.6 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "opensuse-leap-15-5" if TERRAFORM_GCE_IMAGE_OPENLEAP_15_5_X86_64 - default "opensuse-leap-15-6" if TERRAFORM_GCE_IMAGE_OPENLEAP_15_6_X86_64 - -endif # TARGET_ARCH_X86_64 - -endif # TERRAFORM_GCE_DISTRO_OPENSUSE - -if TERRAFORM_GCE_DISTRO_OL - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "oracle-linux-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_OL_8_X86_64 - bool "Oracle Linux 8 (x86)" - -config TERRAFORM_GCE_IMAGE_OL_9_X86_64 - bool "Oracle Linux 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "oracle-linux-8" if TERRAFORM_GCE_IMAGE_OL_8_X86_64 - default "oracle-linux-9" if TERRAFORM_GCE_IMAGE_OL_9_X86_64 - -endif # TARGET_ARCH_X86_64 - -endif # TERRAFORM_GCE_DISTRO_OL - -if TERRAFORM_GCE_DISTRO_RHEL - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "rhel-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -choice - prompt "License type" - default TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - -config TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Pay as you go" - -config TERRAFORM_GCE_LICENSE_TYPE_BYOS_RHEL - bool "Bring your own subscription or license" - -endchoice - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_RHEL_8_X86_64_PAYGO - depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Red Hat Enterprise Linux 8 (x86)" - -config TERRAFORM_GCE_IMAGE_RHEL_9_X86_64_PAYGO - depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Red Hat Enterprise Linux 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rhel-8" if TERRAFORM_GCE_IMAGE_RHEL_8_X86_64_PAYGO - default "rhel-9" if TERRAFORM_GCE_IMAGE_RHEL_9_X86_64_PAYGO - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_RHEL_9_ARM64_PAYGO - depends on TERRAFORM_GCE_LICENSE_TYPE_PAYGO_RHEL - bool "Red Hat Enterprise Linux 9 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rhel-9-arm64" if TERRAFORM_GCE_IMAGE_RHEL_9_ARM64_PAYGO - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_RHEL - -if TERRAFORM_GCE_DISTRO_ROCKY - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "rocky-linux-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 20 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 - -config TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 - bool "Rocky Linux 8 (x86)" - -config TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 - bool "Rocky Linux 9 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rocky-linux-8" if TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 - default "rocky-linux-9" if TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - default TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 - -config TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 - bool "Rocky Linux 9 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "rocky-linux-9-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_ROCKY - -if TERRAFORM_GCE_DISTRO_SLES - -config TERRAFORM_GCE_IMAGE_PROJECT - string - output yaml - default "suse-cloud" - -config TERRAFORM_GCE_IMAGE_SIZE - int - output yaml - default 10 - -if TARGET_ARCH_X86_64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_SLES_12_X86_64 - bool "SUSE Linux Enterprise Server 12 (x86)" - -config TERRAFORM_GCE_IMAGE_SLES_15_X86_64 - bool "SUSE Linux Enterprise Server 15 (x86)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "sles-12" if TERRAFORM_GCE_IMAGE_SLES_12_X86_64 - default "sles-15" if TERRAFORM_GCE_IMAGE_SLES_15_X86_64 - -endif # TARGET_ARCH_X86_64 - -if TARGET_ARCH_ARM64 - -choice - prompt "OS image to use" - -config TERRAFORM_GCE_IMAGE_SLES_15_ARM64 - bool "SUSE Linux Enterprise Server 15 (arm64)" - -endchoice - -config TERRAFORM_GCE_IMAGE_FAMILY - string - output yaml - default "sles-15-arm64" if TERRAFORM_GCE_IMAGE_SLES_15_ARM64 - -endif # TARGET_ARCH_ARM64 - -endif # TERRAFORM_GCE_DISTRO_SLES diff --git a/terraform/gce/kconfigs/Kconfig.image.default b/terraform/gce/kconfigs/Kconfig.image.default new file mode 100644 index 000000000..de3e7ca74 --- /dev/null +++ b/terraform/gce/kconfigs/Kconfig.image.default @@ -0,0 +1,1075 @@ +# This file was auto-generated by gen_kconfig_image +# +# To regenerate: cd terraform/gce/scripts && ./gen_kconfig_image + +choice + prompt "OS Distributor" + default TERRAFORM_GCE_DISTRO_DEBIAN + help + Select the Linux distribution for the OS base image of the + instances to be created. + +config TERRAFORM_GCE_DISTRO_ALMALINUX + bool "AlmaLinux" + +config TERRAFORM_GCE_DISTRO_CENTOS + bool "CentOS" + +config TERRAFORM_GCE_DISTRO_DEBIAN + bool "Debian" + +config TERRAFORM_GCE_DISTRO_FEDORA + bool "Fedora" + +config TERRAFORM_GCE_DISTRO_OPENSUSE + bool "openSUSE" + +config TERRAFORM_GCE_DISTRO_ORACLE + bool "Oracle" + +config TERRAFORM_GCE_DISTRO_REDHAT + bool "Red Hat" + +config TERRAFORM_GCE_DISTRO_ROCKY + bool "Rocky Linux" + +config TERRAFORM_GCE_DISTRO_SUSE + bool "SUSE" + +config TERRAFORM_GCE_DISTRO_UBUNTU + bool "Canonical" + +endchoice + +if TERRAFORM_GCE_DISTRO_ALMALINUX + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "almalinux-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ALMALINUX_9_X86_64 + +config TERRAFORM_GCE_IMAGE_ALMALINUX_8_X86_64 + bool "AlmaLinux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_ALMALINUX_9_X86_64 + bool "AlmaLinux 9 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "almalinux-8" if TERRAFORM_GCE_IMAGE_ALMALINUX_8_X86_64 + default "almalinux-9" if TERRAFORM_GCE_IMAGE_ALMALINUX_9_X86_64 + +endif # TARGET_ARCH_X86_64 + +endif # TERRAFORM_GCE_DISTRO_ALMALINUX + +if TERRAFORM_GCE_DISTRO_CENTOS + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "centos-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_10_X86_64 + +config TERRAFORM_GCE_IMAGE_CENTOS_6_X86_64 + bool "CentOS 6 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_CENTOS_7_X86_64 + bool "CentOS 7 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_CENTOS_8_X86_64 + bool "CentOS 8 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_8_X86_64 + bool "CentOS Stream 8 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 + bool "CentOS Stream 9 (x86)" + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_10_X86_64 + bool "CentOS Stream 10 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "centos-6" if TERRAFORM_GCE_IMAGE_CENTOS_6_X86_64 + default "centos-7" if TERRAFORM_GCE_IMAGE_CENTOS_7_X86_64 + default "centos-8" if TERRAFORM_GCE_IMAGE_CENTOS_8_X86_64 + default "centos-stream-8" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_8_X86_64 + default "centos-stream-9" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_X86_64 + default "centos-stream-10" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_10_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_CENTOS_STREAM_10_ARM64 + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 + bool "CentOS Stream 9 (arm64)" + +config TERRAFORM_GCE_IMAGE_CENTOS_STREAM_10_ARM64 + bool "CentOS Stream 10 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "centos-stream-9-arm64" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_9_ARM64 + default "centos-stream-10-arm64" if TERRAFORM_GCE_IMAGE_CENTOS_STREAM_10_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_CENTOS + +if TERRAFORM_GCE_DISTRO_DEBIAN + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "debian-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_DEBIAN_13_X86_64 + +config TERRAFORM_GCE_IMAGE_DEBIAN_7_X86_64 + bool "Debian 7 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_DEBIAN_8_X86_64 + bool "Debian 8 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_DEBIAN_9_X86_64 + bool "Debian 9 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_DEBIAN_10_X86_64 + bool "Debian 10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 + bool "Debian 11 (x86)" + +config TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 + bool "Debian 12 (x86)" + +config TERRAFORM_GCE_IMAGE_DEBIAN_13_X86_64 + bool "Debian 13 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "debian-7" if TERRAFORM_GCE_IMAGE_DEBIAN_7_X86_64 + default "debian-8" if TERRAFORM_GCE_IMAGE_DEBIAN_8_X86_64 + default "debian-9" if TERRAFORM_GCE_IMAGE_DEBIAN_9_X86_64 + default "debian-10" if TERRAFORM_GCE_IMAGE_DEBIAN_10_X86_64 + default "debian-11" if TERRAFORM_GCE_IMAGE_DEBIAN_11_X86_64 + default "debian-12" if TERRAFORM_GCE_IMAGE_DEBIAN_12_X86_64 + default "debian-13" if TERRAFORM_GCE_IMAGE_DEBIAN_13_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_DEBIAN_13_ARM64 + +config TERRAFORM_GCE_IMAGE_DEBIAN_11_ARM64 + bool "Debian 11 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 + bool "Debian 12 (arm64)" + +config TERRAFORM_GCE_IMAGE_DEBIAN_13_ARM64 + bool "Debian 13 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "debian-11-arm64" if TERRAFORM_GCE_IMAGE_DEBIAN_11_ARM64 + default "debian-12-arm64" if TERRAFORM_GCE_IMAGE_DEBIAN_12_ARM64 + default "debian-13-arm64" if TERRAFORM_GCE_IMAGE_DEBIAN_13_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_DEBIAN + +if TERRAFORM_GCE_DISTRO_FEDORA + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "fedora-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_43_X86_64 + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_RAWHIDE_X86_64 + bool "Fedora Linux Cloud Rawhide (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_ELN_X86_64 + bool "Fedora Linux Cloud Eln (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_33_X86_64 + bool "Fedora Linux Cloud 33 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_34_X86_64 + bool "Fedora Linux Cloud 34 (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_35_X86_64 + bool "Fedora Linux Cloud 35 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_36_X86_64 + bool "Fedora Linux Cloud 36 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_37_X86_64 + bool "Fedora Linux Cloud 37 (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_38_X86_64 + bool "Fedora Linux Cloud 38 (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_39_X86_64 + bool "Fedora Linux Cloud 39 (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_42_X86_64 + bool "Fedora Linux Cloud 42 (x86)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_43_X86_64 + bool "Fedora Linux Cloud 43 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "fedora-cloud-rawhide-x86-64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_RAWHIDE_X86_64 + default "fedora-cloud-eln-x86-64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_ELN_X86_64 + default "fedora-cloud-33" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_33_X86_64 + default "fedora-cloud-34" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_34_X86_64 + default "fedora-cloud-35" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_35_X86_64 + default "fedora-cloud-36" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_36_X86_64 + default "fedora-cloud-37" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_37_X86_64 + default "fedora-cloud-38" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_38_X86_64 + default "fedora-cloud-39" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_39_X86_64 + default "fedora-cloud-42-x86-64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_42_X86_64 + default "fedora-cloud-43-x86-64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_43_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_43_ARM64 + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_RAWHIDE_ARM64 + bool "Fedora Linux Cloud Rawhide (arm64)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_ELN_ARM64 + bool "Fedora Linux Cloud Eln (arm64)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_42_ARM64 + bool "Fedora Linux Cloud 42 (arm64)" + +config TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_43_ARM64 + bool "Fedora Linux Cloud 43 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "fedora-cloud-rawhide-aarch64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_RAWHIDE_ARM64 + default "fedora-cloud-eln-aarch64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_ELN_ARM64 + default "fedora-cloud-42-aarch64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_42_ARM64 + default "fedora-cloud-43-aarch64" if TERRAFORM_GCE_IMAGE_FEDORA_CLOUD_43_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_FEDORA + +if TERRAFORM_GCE_DISTRO_OPENSUSE + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "opensuse-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_OPENSUSE_LEAP_X86_64 + +config TERRAFORM_GCE_IMAGE_OPENSUSE_LEAP_X86_64 + bool "openSUSE Leap (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "opensuse-leap" if TERRAFORM_GCE_IMAGE_OPENSUSE_LEAP_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_OPENSUSE_LEAP_ARM64 + +config TERRAFORM_GCE_IMAGE_OPENSUSE_LEAP_ARM64 + bool "openSUSE Leap (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "opensuse-leap-arm64" if TERRAFORM_GCE_IMAGE_OPENSUSE_LEAP_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_OPENSUSE + +if TERRAFORM_GCE_DISTRO_ORACLE + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "oracle-linux-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ORACLE_10_X86_64 + +config TERRAFORM_GCE_IMAGE_ORACLE_8_X86_64 + bool "Oracle Linux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_ORACLE_9_X86_64 + bool "Oracle Linux 9 (x86)" + +config TERRAFORM_GCE_IMAGE_ORACLE_10_X86_64 + bool "Oracle Linux 10 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "oracle-linux-8" if TERRAFORM_GCE_IMAGE_ORACLE_8_X86_64 + default "oracle-linux-9" if TERRAFORM_GCE_IMAGE_ORACLE_9_X86_64 + default "oracle-linux-10" if TERRAFORM_GCE_IMAGE_ORACLE_10_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ORACLE_10_ARM64 + +config TERRAFORM_GCE_IMAGE_ORACLE_8_ARM64 + bool "Oracle Linux 8 (arm64)" + +config TERRAFORM_GCE_IMAGE_ORACLE_9_ARM64 + bool "Oracle Linux 9 (arm64)" + +config TERRAFORM_GCE_IMAGE_ORACLE_10_ARM64 + bool "Oracle Linux 10 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "oracle-linux-8-arm64" if TERRAFORM_GCE_IMAGE_ORACLE_8_ARM64 + default "oracle-linux-9-arm64" if TERRAFORM_GCE_IMAGE_ORACLE_9_ARM64 + default "oracle-linux-10-arm64" if TERRAFORM_GCE_IMAGE_ORACLE_10_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_ORACLE + +if TERRAFORM_GCE_DISTRO_REDHAT + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "rhel-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_REDHAT_10_X86_64 + +config TERRAFORM_GCE_IMAGE_REDHAT_6_X86_64 + bool "Red Hat Enterprise Linux 6 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_REDHAT_7_X86_64 + bool "Red Hat Enterprise Linux 7 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_REDHAT_8_X86_64 + bool "Red Hat Enterprise Linux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_REDHAT_9_X86_64 + bool "Red Hat Enterprise Linux 9 (x86)" + +config TERRAFORM_GCE_IMAGE_REDHAT_10_X86_64 + bool "Red Hat Enterprise Linux 10 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rhel-6" if TERRAFORM_GCE_IMAGE_REDHAT_6_X86_64 + default "rhel-7" if TERRAFORM_GCE_IMAGE_REDHAT_7_X86_64 + default "rhel-8" if TERRAFORM_GCE_IMAGE_REDHAT_8_X86_64 + default "rhel-9" if TERRAFORM_GCE_IMAGE_REDHAT_9_X86_64 + default "rhel-10" if TERRAFORM_GCE_IMAGE_REDHAT_10_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_REDHAT_10_ARM64 + +config TERRAFORM_GCE_IMAGE_REDHAT_8_ARM64 + bool "Red Hat Enterprise Linux 8 (arm64)" + +config TERRAFORM_GCE_IMAGE_REDHAT_9_ARM64 + bool "Red Hat Enterprise Linux 9 (arm64)" + +config TERRAFORM_GCE_IMAGE_REDHAT_10_ARM64 + bool "Red Hat Enterprise Linux 10 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rhel-8-arm64" if TERRAFORM_GCE_IMAGE_REDHAT_8_ARM64 + default "rhel-9-arm64" if TERRAFORM_GCE_IMAGE_REDHAT_9_ARM64 + default "rhel-10-arm64" if TERRAFORM_GCE_IMAGE_REDHAT_10_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_REDHAT + +if TERRAFORM_GCE_DISTRO_ROCKY + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "rocky-linux-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 20 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ROCKY_10_X86_64 + +config TERRAFORM_GCE_IMAGE_ROCKY_8_OPTIMIZED_X86_64 + bool "Rocky Linux 8 (GCP Optimized) (x86)" + +config TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 + bool "Rocky Linux 8 (x86)" + +config TERRAFORM_GCE_IMAGE_ROCKY_9_OPTIMIZED_X86_64 + bool "Rocky Linux 9 (GCP Optimized) (x86)" + +config TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 + bool "Rocky Linux 9 (x86)" + +config TERRAFORM_GCE_IMAGE_ROCKY_10_OPTIMIZED_X86_64 + bool "Rocky Linux 10 (GCP Optimized) (x86)" + +config TERRAFORM_GCE_IMAGE_ROCKY_10_X86_64 + bool "Rocky Linux 10 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rocky-linux-8-optimized-gcp" if TERRAFORM_GCE_IMAGE_ROCKY_8_OPTIMIZED_X86_64 + default "rocky-linux-8" if TERRAFORM_GCE_IMAGE_ROCKY_8_X86_64 + default "rocky-linux-9-optimized-gcp" if TERRAFORM_GCE_IMAGE_ROCKY_9_OPTIMIZED_X86_64 + default "rocky-linux-9" if TERRAFORM_GCE_IMAGE_ROCKY_9_X86_64 + default "rocky-linux-10-optimized-gcp" if TERRAFORM_GCE_IMAGE_ROCKY_10_OPTIMIZED_X86_64 + default "rocky-linux-10" if TERRAFORM_GCE_IMAGE_ROCKY_10_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_ROCKY_10_OPTIMIZED_ARM64 + +config TERRAFORM_GCE_IMAGE_ROCKY_8_ARM64 + bool "Rocky Linux 8 (arm64)" + +config TERRAFORM_GCE_IMAGE_ROCKY_8_OPTIMIZED_ARM64 + bool "Rocky Linux 8 (GCP Optimized) (arm64)" + +config TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 + bool "Rocky Linux 9 (arm64)" + +config TERRAFORM_GCE_IMAGE_ROCKY_9_OPTIMIZED_ARM64 + bool "Rocky Linux 9 (GCP Optimized) (arm64)" + +config TERRAFORM_GCE_IMAGE_ROCKY_10_ARM64 + bool "Rocky Linux 10 (arm64)" + +config TERRAFORM_GCE_IMAGE_ROCKY_10_OPTIMIZED_ARM64 + bool "Rocky Linux 10 (GCP Optimized) (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "rocky-linux-8-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_8_ARM64 + default "rocky-linux-8-optimized-gcp-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_8_OPTIMIZED_ARM64 + default "rocky-linux-9-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_9_ARM64 + default "rocky-linux-9-optimized-gcp-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_9_OPTIMIZED_ARM64 + default "rocky-linux-10-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_10_ARM64 + default "rocky-linux-10-optimized-gcp-arm64" if TERRAFORM_GCE_IMAGE_ROCKY_10_OPTIMIZED_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_ROCKY + +if TERRAFORM_GCE_DISTRO_SUSE + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "suse-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_SUSE_16_0_X86_64 + +config TERRAFORM_GCE_IMAGE_SUSE_12_X86_64 + bool "SUSE Linux Enterprise Server 12 (x86)" + +config TERRAFORM_GCE_IMAGE_SUSE_15_X86_64 + bool "SUSE Linux Enterprise Server 15 (x86)" + +config TERRAFORM_GCE_IMAGE_SUSE_15_SP5_X86_64 + bool "SUSE Linux Enterprise Server 15 SP5 (x86)" + +config TERRAFORM_GCE_IMAGE_SUSE_15_SP6_X86_64 + bool "SUSE Linux Enterprise Server 15 SP6 (x86)" + +config TERRAFORM_GCE_IMAGE_SUSE_16_0_X86_64 + bool "SUSE Linux Enterprise Server 16.0 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "sles-12" if TERRAFORM_GCE_IMAGE_SUSE_12_X86_64 + default "sles-15" if TERRAFORM_GCE_IMAGE_SUSE_15_X86_64 + default "sles-15-sp5" if TERRAFORM_GCE_IMAGE_SUSE_15_SP5_X86_64 + default "sles-15-sp6" if TERRAFORM_GCE_IMAGE_SUSE_15_SP6_X86_64 + default "sles-16-0-x86-64" if TERRAFORM_GCE_IMAGE_SUSE_16_0_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_SUSE_16_0_ARM64 + +config TERRAFORM_GCE_IMAGE_SUSE_15_SP5_ARM64 + bool "SUSE Linux Enterprise Server 15 SP5 (arm64)" + +config TERRAFORM_GCE_IMAGE_SUSE_15_SP6_ARM64 + bool "SUSE Linux Enterprise Server 15 SP6 (arm64)" + +config TERRAFORM_GCE_IMAGE_SUSE_15_ARM64 + bool "SUSE Linux Enterprise Server 15 (arm64)" + +config TERRAFORM_GCE_IMAGE_SUSE_16_0_ARM64 + bool "SUSE Linux Enterprise Server 16.0 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "sles-15-sp5-arm64" if TERRAFORM_GCE_IMAGE_SUSE_15_SP5_ARM64 + default "sles-15-sp6-arm64" if TERRAFORM_GCE_IMAGE_SUSE_15_SP6_ARM64 + default "sles-15-arm64" if TERRAFORM_GCE_IMAGE_SUSE_15_ARM64 + default "sles-16-0-arm64" if TERRAFORM_GCE_IMAGE_SUSE_16_0_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_SUSE + +if TERRAFORM_GCE_DISTRO_UBUNTU + +config TERRAFORM_GCE_IMAGE_PROJECT + string + output yaml + default "ubuntu-os-cloud" + +config TERRAFORM_GCE_IMAGE_SIZE + int + output yaml + default 10 + +if TARGET_ARCH_X86_64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_10_X86_64 + +config TERRAFORM_GCE_IMAGE_UBUNTU_12_04_LTS_X86_64 + bool "Ubuntu 12.04 LTS (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_14_04_LTS_X86_64 + bool "Ubuntu 14.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_15_10_X86_64 + bool "Ubuntu 15.10 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_16_04_LTS_X86_64 + bool "Ubuntu 16.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_16_04_LTS_X86_64 + bool "Ubuntu Minimal 16.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_16_10_X86_64 + bool "Ubuntu 16.10 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_17_04_X86_64 + bool "Ubuntu 17.04 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_17_10_X86_64 + bool "Ubuntu 17.10 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_18_04_LTS_X86_64 + bool "Ubuntu 18.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_18_04_LTS_X86_64 + bool "Ubuntu Minimal 18.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_18_10_X86_64 + bool "Ubuntu 18.10 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_18_10_X86_64 + bool "Ubuntu Minimal 18.10 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_19_04_X86_64 + bool "Ubuntu 19.04 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_19_04_X86_64 + bool "Ubuntu Minimal 19.04 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_19_10_X86_64 + bool "Ubuntu 19.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_19_10_X86_64 + bool "Ubuntu Minimal 19.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_20_04_LTS_X86_64 + bool "Ubuntu 20.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_20_04_LTS_X86_64 + bool "Ubuntu Minimal 20.04 LTS (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_20_10_X86_64 + bool "Ubuntu 20.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_20_10_X86_64 + bool "Ubuntu Minimal 20.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_21_04_X86_64 + bool "Ubuntu 21.04 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_21_04_X86_64 + bool "Ubuntu Minimal 21.04 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_21_10_X86_64 + bool "Ubuntu 21.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_21_10_X86_64 + bool "Ubuntu Minimal 21.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_22_04_LTS_X86_64 + bool "Ubuntu 22.04 LTS (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_04_LTS_X86_64 + bool "Ubuntu Minimal 22.04 LTS (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_22_10_X86_64 + bool "Ubuntu 22.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_10_X86_64 + bool "Ubuntu Minimal 22.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_23_04_X86_64 + bool "Ubuntu 23.04 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_04_X86_64 + bool "Ubuntu Minimal 23.04 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_23_10_X86_64 + bool "Ubuntu 23.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_10_X86_64 + bool "Ubuntu Minimal 23.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_24_04_LTS_X86_64 + bool "Ubuntu 24.04 LTS (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_04_LTS_X86_64 + bool "Ubuntu Minimal 24.04 LTS (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_24_10_X86_64 + bool "Ubuntu 24.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_10_X86_64 + bool "Ubuntu Minimal 24.10 (x86)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_25_04_X86_64 + bool "Ubuntu 25.04 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_04_X86_64 + bool "Ubuntu Minimal 25.04 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_25_10_X86_64 + bool "Ubuntu 25.10 (x86)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_10_X86_64 + bool "Ubuntu Minimal 25.10 (x86)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "ubuntu-1204-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_12_04_LTS_X86_64 + default "ubuntu-1404-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_14_04_LTS_X86_64 + default "ubuntu-1510" if TERRAFORM_GCE_IMAGE_UBUNTU_15_10_X86_64 + default "ubuntu-1604-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_16_04_LTS_X86_64 + default "ubuntu-minimal-1604-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_16_04_LTS_X86_64 + default "ubuntu-1610" if TERRAFORM_GCE_IMAGE_UBUNTU_16_10_X86_64 + default "ubuntu-1704" if TERRAFORM_GCE_IMAGE_UBUNTU_17_04_X86_64 + default "ubuntu-1710" if TERRAFORM_GCE_IMAGE_UBUNTU_17_10_X86_64 + default "ubuntu-1804-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_18_04_LTS_X86_64 + default "ubuntu-minimal-1804-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_18_04_LTS_X86_64 + default "ubuntu-1810" if TERRAFORM_GCE_IMAGE_UBUNTU_18_10_X86_64 + default "ubuntu-minimal-1810" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_18_10_X86_64 + default "ubuntu-1904" if TERRAFORM_GCE_IMAGE_UBUNTU_19_04_X86_64 + default "ubuntu-minimal-1904" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_19_04_X86_64 + default "ubuntu-1910" if TERRAFORM_GCE_IMAGE_UBUNTU_19_10_X86_64 + default "ubuntu-minimal-1910" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_19_10_X86_64 + default "ubuntu-2004-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_20_04_LTS_X86_64 + default "ubuntu-minimal-2004-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_20_04_LTS_X86_64 + default "ubuntu-2010" if TERRAFORM_GCE_IMAGE_UBUNTU_20_10_X86_64 + default "ubuntu-minimal-2010" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_20_10_X86_64 + default "ubuntu-2104" if TERRAFORM_GCE_IMAGE_UBUNTU_21_04_X86_64 + default "ubuntu-minimal-2104" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_21_04_X86_64 + default "ubuntu-2110" if TERRAFORM_GCE_IMAGE_UBUNTU_21_10_X86_64 + default "ubuntu-minimal-2110" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_21_10_X86_64 + default "ubuntu-2204-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_22_04_LTS_X86_64 + default "ubuntu-minimal-2204-lts" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_04_LTS_X86_64 + default "ubuntu-2210-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_22_10_X86_64 + default "ubuntu-minimal-2210-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_10_X86_64 + default "ubuntu-2304-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_23_04_X86_64 + default "ubuntu-minimal-2304-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_04_X86_64 + default "ubuntu-2310-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_23_10_X86_64 + default "ubuntu-minimal-2310-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_10_X86_64 + default "ubuntu-2404-lts-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_24_04_LTS_X86_64 + default "ubuntu-minimal-2404-lts-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_04_LTS_X86_64 + default "ubuntu-2410-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_24_10_X86_64 + default "ubuntu-minimal-2410-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_10_X86_64 + default "ubuntu-2504-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_25_04_X86_64 + default "ubuntu-minimal-2504-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_04_X86_64 + default "ubuntu-2510-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_25_10_X86_64 + default "ubuntu-minimal-2510-amd64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_10_X86_64 + +endif # TARGET_ARCH_X86_64 + +if TARGET_ARCH_ARM64 + +choice + prompt "OS image to use" + default TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_10_ARM64 + +config TERRAFORM_GCE_IMAGE_UBUNTU_18_04_LTS_ARM64 + bool "Ubuntu 18.04 LTS (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_18_04_LTS_ARM64 + bool "Ubuntu Minimal 18.04 LTS (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_20_04_LTS_ARM64 + bool "Ubuntu 20.04 LTS (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_20_04_LTS_ARM64 + bool "Ubuntu Minimal 20.04 LTS (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_22_04_LTS_ARM64 + bool "Ubuntu 22.04 LTS (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_04_LTS_ARM64 + bool "Ubuntu Minimal 22.04 LTS (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_22_10_ARM64 + bool "Ubuntu 22.10 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_10_ARM64 + bool "Ubuntu Minimal 22.10 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_23_04_ARM64 + bool "Ubuntu 23.04 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_04_ARM64 + bool "Ubuntu Minimal 23.04 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_23_10_ARM64 + bool "Ubuntu 23.10 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_10_ARM64 + bool "Ubuntu Minimal 23.10 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_24_04_LTS_ARM64 + bool "Ubuntu 24.04 LTS (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_04_LTS_ARM64 + bool "Ubuntu Minimal 24.04 LTS (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_24_10_ARM64 + bool "Ubuntu 24.10 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_10_ARM64 + bool "Ubuntu Minimal 24.10 (arm64)" + help + This image family is deprecated. + +config TERRAFORM_GCE_IMAGE_UBUNTU_25_04_ARM64 + bool "Ubuntu 25.04 (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_04_ARM64 + bool "Ubuntu Minimal 25.04 (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_25_10_ARM64 + bool "Ubuntu 25.10 (arm64)" + +config TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_10_ARM64 + bool "Ubuntu Minimal 25.10 (arm64)" + +endchoice + +config TERRAFORM_GCE_IMAGE_FAMILY + string + output yaml + default "ubuntu-1804-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_18_04_LTS_ARM64 + default "ubuntu-minimal-1804-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_18_04_LTS_ARM64 + default "ubuntu-2004-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_20_04_LTS_ARM64 + default "ubuntu-minimal-2004-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_20_04_LTS_ARM64 + default "ubuntu-2204-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_22_04_LTS_ARM64 + default "ubuntu-minimal-2204-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_04_LTS_ARM64 + default "ubuntu-2210-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_22_10_ARM64 + default "ubuntu-minimal-2210-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_22_10_ARM64 + default "ubuntu-2304-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_23_04_ARM64 + default "ubuntu-minimal-2304-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_04_ARM64 + default "ubuntu-2310-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_23_10_ARM64 + default "ubuntu-minimal-2310-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_23_10_ARM64 + default "ubuntu-2404-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_24_04_LTS_ARM64 + default "ubuntu-minimal-2404-lts-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_04_LTS_ARM64 + default "ubuntu-2410-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_24_10_ARM64 + default "ubuntu-minimal-2410-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_24_10_ARM64 + default "ubuntu-2504-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_25_04_ARM64 + default "ubuntu-minimal-2504-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_04_ARM64 + default "ubuntu-2510-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_25_10_ARM64 + default "ubuntu-minimal-2510-arm64" if TERRAFORM_GCE_IMAGE_UBUNTU_MINIMAL_25_10_ARM64 + +endif # TARGET_ARCH_ARM64 + +endif # TERRAFORM_GCE_DISTRO_UBUNTU + diff --git a/terraform/gce/kconfigs/Kconfig.location b/terraform/gce/kconfigs/Kconfig.location deleted file mode 100644 index fa8a16cf4..000000000 --- a/terraform/gce/kconfigs/Kconfig.location +++ /dev/null @@ -1,499 +0,0 @@ -choice - prompt "GCE region" - default TERRAFORM_GCE_REGION_US_WEST2 - help - GCE regions are collections of co-located zones. Zones have - high-bandwidth, low-latency network connections to other - zones within the same region. - - For details: - https://cloud.google.com/compute/docs/regions-zones/ - - For guidance selecting a region to use, try: - https://cloud.withgoogle.com/region-picker/ - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1 - bool "asia-south1" - help - Mumbai, India - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2 - bool "asia-south2" - help - Delhi, India - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 - bool "northamerica-northeast1" - help - Montreal, Quebec, Canada - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 - bool "northamerica-northeast2" - help - Toronto, Ontario, Canada - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 - bool "northamerica-south1" - help - Querétaro, Mexico - -config TERRAFORM_GCE_REGION_US_CENTRAL1 - bool "us-central1" - help - Council Bluffs, Iowa, USA - -config TERRAFORM_GCE_REGION_US_EAST1 - bool "us-east1" - help - Moncks Corner, South Carolina, USA - -config TERRAFORM_GCE_REGION_US_EAST4 - bool "us-east4" - help - Ashburn, Virginia, USA - -config TERRAFORM_GCE_REGION_US_EAST5 - bool "us-east5" - help - Columbus, Ohio, USA - -config TERRAFORM_GCE_REGION_US_SOUTH1 - bool "us-south1" - help - Dallas, Texas, USA - -config TERRAFORM_GCE_REGION_US_WEST1 - bool "us-west1" - help - The Dalles, Oregon, USA - -config TERRAFORM_GCE_REGION_US_WEST2 - bool "us-west2" - help - Los Angeles, California, USA - -config TERRAFORM_GCE_REGION_US_WEST3 - bool "us-west3" - help - Salt Lake City, Utah, USA - -config TERRAFORM_GCE_REGION_US_WEST4 - bool "us-west4" - help - Las Vegas, Nevada, USA - -endchoice - -config TERRAFORM_GCE_REGION - string - output yaml - default "asia-south1" if TERRAFORM_GCE_REGION_ASIA_SOUTH1 - default "asia-south2" if TERRAFORM_GCE_REGION_ASIA_SOUTH2 - default "northamerica-northeast1" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 - default "northamerica-northeast2" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 - default "northamerica-south1" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 - default "us-central1" if TERRAFORM_GCE_REGION_US_CENTRAL1 - default "us-east1" if TERRAFORM_GCE_REGION_US_EAST1 - default "us-east4" if TERRAFORM_GCE_REGION_US_EAST4 - default "us-east5" if TERRAFORM_GCE_REGION_US_EAST5 - default "us-south1" if TERRAFORM_GCE_REGION_US_SOUTH1 - default "us-west1" if TERRAFORM_GCE_REGION_US_WEST1 - default "us-west2" if TERRAFORM_GCE_REGION_US_WEST2 - default "us-west3" if TERRAFORM_GCE_REGION_US_WEST3 - default "us-west4" if TERRAFORM_GCE_REGION_US_WEST4 - -if TERRAFORM_GCE_REGION_ASIA_SOUTH1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_ASIA_SOUTH1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1_A - bool "asia-south1-a" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1_B - bool "asia-south1-b" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH1_C - bool "asia-south1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "asia-south1-a" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_A - default "asia-south1-b" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_B - default "asia-south1-c" if TERRAFORM_GCE_REGION_ASIA_SOUTH1_C - -endif # TERRAFORM_GCE_REGION_ASIA_SOUTH1 - -if TERRAFORM_GCE_REGION_ASIA_SOUTH2 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_ASIA_SOUTH2_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2_A - bool "asia-south2-a" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2_B - bool "asia-south2-b" - -config TERRAFORM_GCE_REGION_ASIA_SOUTH2_C - bool "asia-south2-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "asia-south2-a" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_A - default "asia-south2-b" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_B - default "asia-south2-c" if TERRAFORM_GCE_REGION_ASIA_SOUTH2_C - -endif # TERRAFORM_GCE_REGION_ASIA_SOUTH2 - -if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_A - bool "northamerica-northeast1-a" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B - bool "northamerica-northeast1-b" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_C - bool "northamerica-northeast1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "northamerica-northeast1-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_A - default "northamerica-northeast1-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_B - default "northamerica-northeast1-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1_C - -endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 - -if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_A - bool "northamerica-northeast2-a" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B - bool "northamerica-northeast2-b" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_C - bool "northamerica-northeast2-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "northamerica-northeast2-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_A - default "northamerica-northeast2-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_B - default "northamerica-northeast2-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2_C - -endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 - -if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_A - bool "northamerica-south1-a" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B - bool "northamerica-south1-b" - -config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_C - bool "northamerica-south1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "northamerica-south1-a" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_A - default "northamerica-south1-b" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_B - default "northamerica-south1-c" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1_C - -endif # TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 - -if TERRAFORM_GCE_REGION_US_CENTRAL1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_CENTRAL1_C - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_A - bool "us-central1-a" - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_B - bool "us-central1-b" - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_C - bool "us-central1-c" - -config TERRAFORM_GCE_ZONE_US_CENTRAL1_F - bool "us-central1-f" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-central1-a" if TERRAFORM_GCE_ZONE_US_CENTRAL1_A - default "us-central1-b" if TERRAFORM_GCE_ZONE_US_CENTRAL1_B - default "us-central1-c" if TERRAFORM_GCE_ZONE_US_CENTRAL1_C - default "us-central1-f" if TERRAFORM_GCE_ZONE_US_CENTRAL1_F - -endif # TERRAFORM_GCE_REGION_US_CENTRAL1 - -if TERRAFORM_GCE_REGION_US_EAST1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_EAST1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_EAST1_B - bool "us-east1-b" - -config TERRAFORM_GCE_ZONE_US_EAST1_C - bool "us-east1-c" - -config TERRAFORM_GCE_ZONE_US_EAST1_D - bool "us-east1-d" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-east1-b" if TERRAFORM_GCE_ZONE_US_EAST1_B - default "us-east1-c" if TERRAFORM_GCE_ZONE_US_EAST1_C - default "us-east1-d" if TERRAFORM_GCE_ZONE_US_EAST1_D - -endif # TERRAFORM_GCE_REGION_US_EAST1 - -if TERRAFORM_GCE_REGION_US_EAST4 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_EAST4_C - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_EAST4_A - bool "us-east4-a" - -config TERRAFORM_GCE_ZONE_US_EAST4_B - bool "us-east4-b" - -config TERRAFORM_GCE_ZONE_US_EAST4_C - bool "us-east4-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-east4-a" if TERRAFORM_GCE_ZONE_US_EAST4_A - default "us-east4-b" if TERRAFORM_GCE_ZONE_US_EAST4_B - default "us-east4-c" if TERRAFORM_GCE_ZONE_US_EAST4_C - -endif # TERRAFORM_GCE_REGION_US_EAST4 - -if TERRAFORM_GCE_REGION_US_EAST5 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_EAST5_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_EAST5_A - bool "us-east5-a" - -config TERRAFORM_GCE_ZONE_US_EAST5_B - bool "us-east5-b" - -config TERRAFORM_GCE_ZONE_US_EAST5_C - bool "us-east5-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-east5-a" if TERRAFORM_GCE_ZONE_US_EAST5_A - default "us-east5-b" if TERRAFORM_GCE_ZONE_US_EAST5_B - default "us-east5-c" if TERRAFORM_GCE_ZONE_US_EAST5_C - -endif # TERRAFORM_GCE_REGION_US_EAST5 - -if TERRAFORM_GCE_REGION_US_SOUTH1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_SOUTH1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_SOUTH1_A - bool "us-south1-a" - -config TERRAFORM_GCE_ZONE_US_SOUTH1_B - bool "us-south1-b" - -config TERRAFORM_GCE_ZONE_US_SOUTH1_C - bool "us-south1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-south1-a" if TERRAFORM_GCE_ZONE_US_SOUTH1_A - default "us-south1-b" if TERRAFORM_GCE_ZONE_US_SOUTH1_B - default "us-south1-c" if TERRAFORM_GCE_ZONE_US_SOUTH1_C - -endif # TERRAFORM_GCE_REGION_US_SOUTH1 - -if TERRAFORM_GCE_REGION_US_WEST1 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST1_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST1_A - bool "us-west1-a" - -config TERRAFORM_GCE_ZONE_US_WEST1_B - bool "us-west1-b" - -config TERRAFORM_GCE_ZONE_US_WEST1_C - bool "us-west1-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west1-a" if TERRAFORM_GCE_ZONE_US_WEST1_A - default "us-west1-b" if TERRAFORM_GCE_ZONE_US_WEST1_B - default "us-west1-c" if TERRAFORM_GCE_ZONE_US_WEST1_C - -endif # TERRAFORM_GCE_REGION_US_WEST1 - -if TERRAFORM_GCE_REGION_US_WEST2 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST2_C - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST2_A - bool "us-west2-a" - -config TERRAFORM_GCE_ZONE_US_WEST2_B - bool "us-west2-b" - -config TERRAFORM_GCE_ZONE_US_WEST2_C - bool "us-west2-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west2-a" if TERRAFORM_GCE_ZONE_US_WEST2_A - default "us-west2-b" if TERRAFORM_GCE_ZONE_US_WEST2_B - default "us-west2-c" if TERRAFORM_GCE_ZONE_US_WEST2_C - -endif # TERRAFORM_GCE_REGION_US_WEST2 - -if TERRAFORM_GCE_REGION_US_WEST3 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST3_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST3_A - bool "us-west3-a" - -config TERRAFORM_GCE_ZONE_US_WEST3_B - bool "us-west3-b" - -config TERRAFORM_GCE_ZONE_US_WEST3_C - bool "us-west3-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west3-a" if TERRAFORM_GCE_ZONE_US_WEST3_A - default "us-west3-b" if TERRAFORM_GCE_ZONE_US_WEST3_B - default "us-west3-c" if TERRAFORM_GCE_ZONE_US_WEST3_C - -endif # TERRAFORM_GCE_REGION_US_WEST3 - -if TERRAFORM_GCE_REGION_US_WEST4 - -choice - prompt "GCE zone" - default TERRAFORM_GCE_ZONE_US_WEST4_B - help - A zone is a deployment area within a region. - -config TERRAFORM_GCE_ZONE_US_WEST4_A - bool "us-west4-a" - -config TERRAFORM_GCE_ZONE_US_WEST4_B - bool "us-west4-b" - -config TERRAFORM_GCE_ZONE_US_WEST4_C - bool "us-west4-c" - -endchoice - -config TERRAFORM_GCE_ZONE - string - output yaml - default "us-west4-a" if TERRAFORM_GCE_ZONE_US_WEST4_A - default "us-west4-b" if TERRAFORM_GCE_ZONE_US_WEST4_B - default "us-west4-c" if TERRAFORM_GCE_ZONE_US_WEST4_C - -endif # TERRAFORM_GCE_REGION_US_WEST4 diff --git a/terraform/gce/kconfigs/Kconfig.location.default b/terraform/gce/kconfigs/Kconfig.location.default new file mode 100644 index 000000000..118fce3f1 --- /dev/null +++ b/terraform/gce/kconfigs/Kconfig.location.default @@ -0,0 +1,1452 @@ +choice + prompt "GCE region" + default TERRAFORM_GCE_REGION_US_WEST2 + help + GCE regions are collections of co-located zones. Zones have + high-bandwidth, low-latency network connections to other + zones within the same region. + + For details: + https://cloud.google.com/compute/docs/regions-zones/ + + For guidance selecting a region to use, try: + https://cloud.withgoogle.com/region-picker/ + +config TERRAFORM_GCE_REGION_AFRICA_SOUTH1 + bool "africa-south1" + help + Johannesburg, South Africa + +config TERRAFORM_GCE_REGION_ASIA_EAST1 + bool "asia-east1" + help + Changhua County, Taiwan + +config TERRAFORM_GCE_REGION_ASIA_EAST2 + bool "asia-east2" + help + Hong Kong + +config TERRAFORM_GCE_REGION_ASIA_NORTHEAST1 + bool "asia-northeast1" + help + Tokyo, Japan + +config TERRAFORM_GCE_REGION_ASIA_NORTHEAST2 + bool "asia-northeast2" + help + Osaka, Japan + +config TERRAFORM_GCE_REGION_ASIA_NORTHEAST3 + bool "asia-northeast3" + help + Seoul, South Korea + +config TERRAFORM_GCE_REGION_ASIA_SOUTH1 + bool "asia-south1" + help + Mumbai, India + +config TERRAFORM_GCE_REGION_ASIA_SOUTH2 + bool "asia-south2" + help + Delhi, India + +config TERRAFORM_GCE_REGION_ASIA_SOUTHEAST1 + bool "asia-southeast1" + help + Jurong West, Singapore + +config TERRAFORM_GCE_REGION_ASIA_SOUTHEAST2 + bool "asia-southeast2" + help + Jakarta, Indonesia + +config TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST1 + bool "australia-southeast1" + help + Sydney, Australia + +config TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST2 + bool "australia-southeast2" + help + Melbourne, Australia + +config TERRAFORM_GCE_REGION_EUROPE_CENTRAL2 + bool "europe-central2" + help + Warsaw, Poland + +config TERRAFORM_GCE_REGION_EUROPE_NORTH1 + bool "europe-north1" + help + Hamina, Finland + +config TERRAFORM_GCE_REGION_EUROPE_NORTH2 + bool "europe-north2" + help + Stockholm, Sweden + +config TERRAFORM_GCE_REGION_EUROPE_SOUTHWEST1 + bool "europe-southwest1" + help + Madrid, Spain + +config TERRAFORM_GCE_REGION_EUROPE_WEST1 + bool "europe-west1" + help + St. Ghislain, Belgium + +config TERRAFORM_GCE_REGION_EUROPE_WEST10 + bool "europe-west10" + help + Berlin, Germany + +config TERRAFORM_GCE_REGION_EUROPE_WEST12 + bool "europe-west12" + help + Turin, Italy + +config TERRAFORM_GCE_REGION_EUROPE_WEST2 + bool "europe-west2" + help + London, UK + +config TERRAFORM_GCE_REGION_EUROPE_WEST3 + bool "europe-west3" + help + Frankfurt, Germany + +config TERRAFORM_GCE_REGION_EUROPE_WEST4 + bool "europe-west4" + help + Eemshaven, Netherlands + +config TERRAFORM_GCE_REGION_EUROPE_WEST6 + bool "europe-west6" + help + Zurich, Switzerland + +config TERRAFORM_GCE_REGION_EUROPE_WEST8 + bool "europe-west8" + help + Milan, Italy + +config TERRAFORM_GCE_REGION_EUROPE_WEST9 + bool "europe-west9" + help + Paris, France + +config TERRAFORM_GCE_REGION_ME_CENTRAL1 + bool "me-central1" + help + Doha, Qatar + +config TERRAFORM_GCE_REGION_ME_CENTRAL2 + bool "me-central2" + help + Dammam, Saudi Arabia + +config TERRAFORM_GCE_REGION_ME_WEST1 + bool "me-west1" + help + Tel Aviv, Israel + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 + bool "northamerica-northeast1" + help + Montreal, Quebec, Canada + +config TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 + bool "northamerica-northeast2" + help + Toronto, Ontario, Canada + +config TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 + bool "northamerica-south1" + help + Queretaro, Mexico + +config TERRAFORM_GCE_REGION_SOUTHAMERICA_EAST1 + bool "southamerica-east1" + help + Sao Paulo, Brazil + +config TERRAFORM_GCE_REGION_SOUTHAMERICA_WEST1 + bool "southamerica-west1" + help + Santiago, Chile + +config TERRAFORM_GCE_REGION_US_CENTRAL1 + bool "us-central1" + help + Council Bluffs, Iowa, USA + +config TERRAFORM_GCE_REGION_US_EAST1 + bool "us-east1" + help + Moncks Corner, South Carolina, USA + +config TERRAFORM_GCE_REGION_US_EAST4 + bool "us-east4" + help + Ashburn, Virginia, USA + +config TERRAFORM_GCE_REGION_US_EAST5 + bool "us-east5" + help + Columbus, Ohio, USA + +config TERRAFORM_GCE_REGION_US_SOUTH1 + bool "us-south1" + help + Dallas, Texas, USA + +config TERRAFORM_GCE_REGION_US_WEST1 + bool "us-west1" + help + The Dalles, Oregon, USA + +config TERRAFORM_GCE_REGION_US_WEST2 + bool "us-west2" + help + Los Angeles, California, USA + +config TERRAFORM_GCE_REGION_US_WEST3 + bool "us-west3" + help + Salt Lake City, Utah, USA + +config TERRAFORM_GCE_REGION_US_WEST4 + bool "us-west4" + help + Las Vegas, Nevada, USA + +endchoice + +config TERRAFORM_GCE_REGION + string + output yaml + default "africa-south1" if TERRAFORM_GCE_REGION_AFRICA_SOUTH1 + default "asia-east1" if TERRAFORM_GCE_REGION_ASIA_EAST1 + default "asia-east2" if TERRAFORM_GCE_REGION_ASIA_EAST2 + default "asia-northeast1" if TERRAFORM_GCE_REGION_ASIA_NORTHEAST1 + default "asia-northeast2" if TERRAFORM_GCE_REGION_ASIA_NORTHEAST2 + default "asia-northeast3" if TERRAFORM_GCE_REGION_ASIA_NORTHEAST3 + default "asia-south1" if TERRAFORM_GCE_REGION_ASIA_SOUTH1 + default "asia-south2" if TERRAFORM_GCE_REGION_ASIA_SOUTH2 + default "asia-southeast1" if TERRAFORM_GCE_REGION_ASIA_SOUTHEAST1 + default "asia-southeast2" if TERRAFORM_GCE_REGION_ASIA_SOUTHEAST2 + default "australia-southeast1" if TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST1 + default "australia-southeast2" if TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST2 + default "europe-central2" if TERRAFORM_GCE_REGION_EUROPE_CENTRAL2 + default "europe-north1" if TERRAFORM_GCE_REGION_EUROPE_NORTH1 + default "europe-north2" if TERRAFORM_GCE_REGION_EUROPE_NORTH2 + default "europe-southwest1" if TERRAFORM_GCE_REGION_EUROPE_SOUTHWEST1 + default "europe-west1" if TERRAFORM_GCE_REGION_EUROPE_WEST1 + default "europe-west10" if TERRAFORM_GCE_REGION_EUROPE_WEST10 + default "europe-west12" if TERRAFORM_GCE_REGION_EUROPE_WEST12 + default "europe-west2" if TERRAFORM_GCE_REGION_EUROPE_WEST2 + default "europe-west3" if TERRAFORM_GCE_REGION_EUROPE_WEST3 + default "europe-west4" if TERRAFORM_GCE_REGION_EUROPE_WEST4 + default "europe-west6" if TERRAFORM_GCE_REGION_EUROPE_WEST6 + default "europe-west8" if TERRAFORM_GCE_REGION_EUROPE_WEST8 + default "europe-west9" if TERRAFORM_GCE_REGION_EUROPE_WEST9 + default "me-central1" if TERRAFORM_GCE_REGION_ME_CENTRAL1 + default "me-central2" if TERRAFORM_GCE_REGION_ME_CENTRAL2 + default "me-west1" if TERRAFORM_GCE_REGION_ME_WEST1 + default "northamerica-northeast1" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 + default "northamerica-northeast2" if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 + default "northamerica-south1" if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 + default "southamerica-east1" if TERRAFORM_GCE_REGION_SOUTHAMERICA_EAST1 + default "southamerica-west1" if TERRAFORM_GCE_REGION_SOUTHAMERICA_WEST1 + default "us-central1" if TERRAFORM_GCE_REGION_US_CENTRAL1 + default "us-east1" if TERRAFORM_GCE_REGION_US_EAST1 + default "us-east4" if TERRAFORM_GCE_REGION_US_EAST4 + default "us-east5" if TERRAFORM_GCE_REGION_US_EAST5 + default "us-south1" if TERRAFORM_GCE_REGION_US_SOUTH1 + default "us-west1" if TERRAFORM_GCE_REGION_US_WEST1 + default "us-west2" if TERRAFORM_GCE_REGION_US_WEST2 + default "us-west3" if TERRAFORM_GCE_REGION_US_WEST3 + default "us-west4" if TERRAFORM_GCE_REGION_US_WEST4 + + +if TERRAFORM_GCE_REGION_AFRICA_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_A + bool "africa-south1-a" + +config TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_B + bool "africa-south1-b" + +config TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_C + bool "africa-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "africa-south1-a" if TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_A + default "africa-south1-b" if TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_B + default "africa-south1-c" if TERRAFORM_GCE_ZONE_AFRICA_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_AFRICA_SOUTH1 + +if TERRAFORM_GCE_REGION_ASIA_EAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_EAST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_EAST1_A + bool "asia-east1-a" + +config TERRAFORM_GCE_ZONE_ASIA_EAST1_B + bool "asia-east1-b" + +config TERRAFORM_GCE_ZONE_ASIA_EAST1_C + bool "asia-east1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-east1-a" if TERRAFORM_GCE_ZONE_ASIA_EAST1_A + default "asia-east1-b" if TERRAFORM_GCE_ZONE_ASIA_EAST1_B + default "asia-east1-c" if TERRAFORM_GCE_ZONE_ASIA_EAST1_C + +endif # TERRAFORM_GCE_REGION_ASIA_EAST1 + +if TERRAFORM_GCE_REGION_ASIA_EAST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_EAST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_EAST2_A + bool "asia-east2-a" + +config TERRAFORM_GCE_ZONE_ASIA_EAST2_B + bool "asia-east2-b" + +config TERRAFORM_GCE_ZONE_ASIA_EAST2_C + bool "asia-east2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-east2-a" if TERRAFORM_GCE_ZONE_ASIA_EAST2_A + default "asia-east2-b" if TERRAFORM_GCE_ZONE_ASIA_EAST2_B + default "asia-east2-c" if TERRAFORM_GCE_ZONE_ASIA_EAST2_C + +endif # TERRAFORM_GCE_REGION_ASIA_EAST2 + +if TERRAFORM_GCE_REGION_ASIA_NORTHEAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_A + bool "asia-northeast1-a" + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_B + bool "asia-northeast1-b" + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_C + bool "asia-northeast1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-northeast1-a" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_A + default "asia-northeast1-b" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_B + default "asia-northeast1-c" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST1_C + +endif # TERRAFORM_GCE_REGION_ASIA_NORTHEAST1 + +if TERRAFORM_GCE_REGION_ASIA_NORTHEAST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_A + bool "asia-northeast2-a" + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_B + bool "asia-northeast2-b" + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_C + bool "asia-northeast2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-northeast2-a" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_A + default "asia-northeast2-b" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_B + default "asia-northeast2-c" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST2_C + +endif # TERRAFORM_GCE_REGION_ASIA_NORTHEAST2 + +if TERRAFORM_GCE_REGION_ASIA_NORTHEAST3 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_A + bool "asia-northeast3-a" + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_B + bool "asia-northeast3-b" + +config TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_C + bool "asia-northeast3-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-northeast3-a" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_A + default "asia-northeast3-b" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_B + default "asia-northeast3-c" if TERRAFORM_GCE_ZONE_ASIA_NORTHEAST3_C + +endif # TERRAFORM_GCE_REGION_ASIA_NORTHEAST3 + +if TERRAFORM_GCE_REGION_ASIA_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_SOUTH1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_SOUTH1_A + bool "asia-south1-a" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTH1_B + bool "asia-south1-b" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTH1_C + bool "asia-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-south1-a" if TERRAFORM_GCE_ZONE_ASIA_SOUTH1_A + default "asia-south1-b" if TERRAFORM_GCE_ZONE_ASIA_SOUTH1_B + default "asia-south1-c" if TERRAFORM_GCE_ZONE_ASIA_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_ASIA_SOUTH1 + +if TERRAFORM_GCE_REGION_ASIA_SOUTH2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_SOUTH2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_SOUTH2_A + bool "asia-south2-a" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTH2_B + bool "asia-south2-b" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTH2_C + bool "asia-south2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-south2-a" if TERRAFORM_GCE_ZONE_ASIA_SOUTH2_A + default "asia-south2-b" if TERRAFORM_GCE_ZONE_ASIA_SOUTH2_B + default "asia-south2-c" if TERRAFORM_GCE_ZONE_ASIA_SOUTH2_C + +endif # TERRAFORM_GCE_REGION_ASIA_SOUTH2 + +if TERRAFORM_GCE_REGION_ASIA_SOUTHEAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_A + bool "asia-southeast1-a" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_B + bool "asia-southeast1-b" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_C + bool "asia-southeast1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-southeast1-a" if TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_A + default "asia-southeast1-b" if TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_B + default "asia-southeast1-c" if TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST1_C + +endif # TERRAFORM_GCE_REGION_ASIA_SOUTHEAST1 + +if TERRAFORM_GCE_REGION_ASIA_SOUTHEAST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_A + bool "asia-southeast2-a" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_B + bool "asia-southeast2-b" + +config TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_C + bool "asia-southeast2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "asia-southeast2-a" if TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_A + default "asia-southeast2-b" if TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_B + default "asia-southeast2-c" if TERRAFORM_GCE_ZONE_ASIA_SOUTHEAST2_C + +endif # TERRAFORM_GCE_REGION_ASIA_SOUTHEAST2 + +if TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_A + bool "australia-southeast1-a" + +config TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_B + bool "australia-southeast1-b" + +config TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_C + bool "australia-southeast1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "australia-southeast1-a" if TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_A + default "australia-southeast1-b" if TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_B + default "australia-southeast1-c" if TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST1_C + +endif # TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST1 + +if TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_A + bool "australia-southeast2-a" + +config TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_B + bool "australia-southeast2-b" + +config TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_C + bool "australia-southeast2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "australia-southeast2-a" if TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_A + default "australia-southeast2-b" if TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_B + default "australia-southeast2-c" if TERRAFORM_GCE_ZONE_AUSTRALIA_SOUTHEAST2_C + +endif # TERRAFORM_GCE_REGION_AUSTRALIA_SOUTHEAST2 + +if TERRAFORM_GCE_REGION_EUROPE_CENTRAL2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_A + bool "europe-central2-a" + +config TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_B + bool "europe-central2-b" + +config TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_C + bool "europe-central2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-central2-a" if TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_A + default "europe-central2-b" if TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_B + default "europe-central2-c" if TERRAFORM_GCE_ZONE_EUROPE_CENTRAL2_C + +endif # TERRAFORM_GCE_REGION_EUROPE_CENTRAL2 + +if TERRAFORM_GCE_REGION_EUROPE_NORTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_NORTH1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_NORTH1_A + bool "europe-north1-a" + +config TERRAFORM_GCE_ZONE_EUROPE_NORTH1_B + bool "europe-north1-b" + +config TERRAFORM_GCE_ZONE_EUROPE_NORTH1_C + bool "europe-north1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-north1-a" if TERRAFORM_GCE_ZONE_EUROPE_NORTH1_A + default "europe-north1-b" if TERRAFORM_GCE_ZONE_EUROPE_NORTH1_B + default "europe-north1-c" if TERRAFORM_GCE_ZONE_EUROPE_NORTH1_C + +endif # TERRAFORM_GCE_REGION_EUROPE_NORTH1 + +if TERRAFORM_GCE_REGION_EUROPE_NORTH2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_NORTH2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_NORTH2_A + bool "europe-north2-a" + +config TERRAFORM_GCE_ZONE_EUROPE_NORTH2_B + bool "europe-north2-b" + +config TERRAFORM_GCE_ZONE_EUROPE_NORTH2_C + bool "europe-north2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-north2-a" if TERRAFORM_GCE_ZONE_EUROPE_NORTH2_A + default "europe-north2-b" if TERRAFORM_GCE_ZONE_EUROPE_NORTH2_B + default "europe-north2-c" if TERRAFORM_GCE_ZONE_EUROPE_NORTH2_C + +endif # TERRAFORM_GCE_REGION_EUROPE_NORTH2 + +if TERRAFORM_GCE_REGION_EUROPE_SOUTHWEST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_A + bool "europe-southwest1-a" + +config TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_B + bool "europe-southwest1-b" + +config TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_C + bool "europe-southwest1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-southwest1-a" if TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_A + default "europe-southwest1-b" if TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_B + default "europe-southwest1-c" if TERRAFORM_GCE_ZONE_EUROPE_SOUTHWEST1_C + +endif # TERRAFORM_GCE_REGION_EUROPE_SOUTHWEST1 + +if TERRAFORM_GCE_REGION_EUROPE_WEST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST1_B + bool "europe-west1-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST1_C + bool "europe-west1-c" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST1_D + bool "europe-west1-d" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west1-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST1_B + default "europe-west1-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST1_C + default "europe-west1-d" if TERRAFORM_GCE_ZONE_EUROPE_WEST1_D + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST1 + +if TERRAFORM_GCE_REGION_EUROPE_WEST10 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST10_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST10_A + bool "europe-west10-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST10_B + bool "europe-west10-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST10_C + bool "europe-west10-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west10-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST10_A + default "europe-west10-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST10_B + default "europe-west10-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST10_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST10 + +if TERRAFORM_GCE_REGION_EUROPE_WEST12 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST12_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST12_A + bool "europe-west12-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST12_B + bool "europe-west12-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST12_C + bool "europe-west12-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west12-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST12_A + default "europe-west12-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST12_B + default "europe-west12-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST12_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST12 + +if TERRAFORM_GCE_REGION_EUROPE_WEST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST2_A + bool "europe-west2-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST2_B + bool "europe-west2-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST2_C + bool "europe-west2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west2-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST2_A + default "europe-west2-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST2_B + default "europe-west2-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST2_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST2 + +if TERRAFORM_GCE_REGION_EUROPE_WEST3 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST3_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST3_A + bool "europe-west3-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST3_B + bool "europe-west3-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST3_C + bool "europe-west3-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west3-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST3_A + default "europe-west3-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST3_B + default "europe-west3-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST3_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST3 + +if TERRAFORM_GCE_REGION_EUROPE_WEST4 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST4_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST4_A + bool "europe-west4-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST4_B + bool "europe-west4-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST4_C + bool "europe-west4-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west4-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST4_A + default "europe-west4-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST4_B + default "europe-west4-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST4_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST4 + +if TERRAFORM_GCE_REGION_EUROPE_WEST6 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST6_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST6_A + bool "europe-west6-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST6_B + bool "europe-west6-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST6_C + bool "europe-west6-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west6-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST6_A + default "europe-west6-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST6_B + default "europe-west6-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST6_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST6 + +if TERRAFORM_GCE_REGION_EUROPE_WEST8 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST8_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST8_A + bool "europe-west8-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST8_B + bool "europe-west8-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST8_C + bool "europe-west8-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west8-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST8_A + default "europe-west8-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST8_B + default "europe-west8-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST8_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST8 + +if TERRAFORM_GCE_REGION_EUROPE_WEST9 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_EUROPE_WEST9_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_EUROPE_WEST9_A + bool "europe-west9-a" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST9_B + bool "europe-west9-b" + +config TERRAFORM_GCE_ZONE_EUROPE_WEST9_C + bool "europe-west9-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "europe-west9-a" if TERRAFORM_GCE_ZONE_EUROPE_WEST9_A + default "europe-west9-b" if TERRAFORM_GCE_ZONE_EUROPE_WEST9_B + default "europe-west9-c" if TERRAFORM_GCE_ZONE_EUROPE_WEST9_C + +endif # TERRAFORM_GCE_REGION_EUROPE_WEST9 + +if TERRAFORM_GCE_REGION_ME_CENTRAL1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ME_CENTRAL1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ME_CENTRAL1_A + bool "me-central1-a" + +config TERRAFORM_GCE_ZONE_ME_CENTRAL1_B + bool "me-central1-b" + +config TERRAFORM_GCE_ZONE_ME_CENTRAL1_C + bool "me-central1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "me-central1-a" if TERRAFORM_GCE_ZONE_ME_CENTRAL1_A + default "me-central1-b" if TERRAFORM_GCE_ZONE_ME_CENTRAL1_B + default "me-central1-c" if TERRAFORM_GCE_ZONE_ME_CENTRAL1_C + +endif # TERRAFORM_GCE_REGION_ME_CENTRAL1 + +if TERRAFORM_GCE_REGION_ME_CENTRAL2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ME_CENTRAL2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ME_CENTRAL2_A + bool "me-central2-a" + +config TERRAFORM_GCE_ZONE_ME_CENTRAL2_B + bool "me-central2-b" + +config TERRAFORM_GCE_ZONE_ME_CENTRAL2_C + bool "me-central2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "me-central2-a" if TERRAFORM_GCE_ZONE_ME_CENTRAL2_A + default "me-central2-b" if TERRAFORM_GCE_ZONE_ME_CENTRAL2_B + default "me-central2-c" if TERRAFORM_GCE_ZONE_ME_CENTRAL2_C + +endif # TERRAFORM_GCE_REGION_ME_CENTRAL2 + +if TERRAFORM_GCE_REGION_ME_WEST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_ME_WEST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_ME_WEST1_A + bool "me-west1-a" + +config TERRAFORM_GCE_ZONE_ME_WEST1_B + bool "me-west1-b" + +config TERRAFORM_GCE_ZONE_ME_WEST1_C + bool "me-west1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "me-west1-a" if TERRAFORM_GCE_ZONE_ME_WEST1_A + default "me-west1-b" if TERRAFORM_GCE_ZONE_ME_WEST1_B + default "me-west1-c" if TERRAFORM_GCE_ZONE_ME_WEST1_C + +endif # TERRAFORM_GCE_REGION_ME_WEST1 + +if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_A + bool "northamerica-northeast1-a" + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_B + bool "northamerica-northeast1-b" + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_C + bool "northamerica-northeast1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "northamerica-northeast1-a" if TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_A + default "northamerica-northeast1-b" if TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_B + default "northamerica-northeast1-c" if TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST1_C + +endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST1 + +if TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_A + bool "northamerica-northeast2-a" + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_B + bool "northamerica-northeast2-b" + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_C + bool "northamerica-northeast2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "northamerica-northeast2-a" if TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_A + default "northamerica-northeast2-b" if TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_B + default "northamerica-northeast2-c" if TERRAFORM_GCE_ZONE_NORTHAMERICA_NORTHEAST2_C + +endif # TERRAFORM_GCE_REGION_NORTHAMERICA_NORTHEAST2 + +if TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_A + bool "northamerica-south1-a" + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_B + bool "northamerica-south1-b" + +config TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_C + bool "northamerica-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "northamerica-south1-a" if TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_A + default "northamerica-south1-b" if TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_B + default "northamerica-south1-c" if TERRAFORM_GCE_ZONE_NORTHAMERICA_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_NORTHAMERICA_SOUTH1 + +if TERRAFORM_GCE_REGION_SOUTHAMERICA_EAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_A + bool "southamerica-east1-a" + +config TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_B + bool "southamerica-east1-b" + +config TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_C + bool "southamerica-east1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "southamerica-east1-a" if TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_A + default "southamerica-east1-b" if TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_B + default "southamerica-east1-c" if TERRAFORM_GCE_ZONE_SOUTHAMERICA_EAST1_C + +endif # TERRAFORM_GCE_REGION_SOUTHAMERICA_EAST1 + +if TERRAFORM_GCE_REGION_SOUTHAMERICA_WEST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_A + bool "southamerica-west1-a" + +config TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_B + bool "southamerica-west1-b" + +config TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_C + bool "southamerica-west1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "southamerica-west1-a" if TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_A + default "southamerica-west1-b" if TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_B + default "southamerica-west1-c" if TERRAFORM_GCE_ZONE_SOUTHAMERICA_WEST1_C + +endif # TERRAFORM_GCE_REGION_SOUTHAMERICA_WEST1 + +if TERRAFORM_GCE_REGION_US_CENTRAL1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_CENTRAL1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_A + bool "us-central1-a" + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_B + bool "us-central1-b" + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_C + bool "us-central1-c" + +config TERRAFORM_GCE_ZONE_US_CENTRAL1_F + bool "us-central1-f" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-central1-a" if TERRAFORM_GCE_ZONE_US_CENTRAL1_A + default "us-central1-b" if TERRAFORM_GCE_ZONE_US_CENTRAL1_B + default "us-central1-c" if TERRAFORM_GCE_ZONE_US_CENTRAL1_C + default "us-central1-f" if TERRAFORM_GCE_ZONE_US_CENTRAL1_F + +endif # TERRAFORM_GCE_REGION_US_CENTRAL1 + +if TERRAFORM_GCE_REGION_US_EAST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_EAST1_B + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_EAST1_B + bool "us-east1-b" + +config TERRAFORM_GCE_ZONE_US_EAST1_C + bool "us-east1-c" + +config TERRAFORM_GCE_ZONE_US_EAST1_D + bool "us-east1-d" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-east1-b" if TERRAFORM_GCE_ZONE_US_EAST1_B + default "us-east1-c" if TERRAFORM_GCE_ZONE_US_EAST1_C + default "us-east1-d" if TERRAFORM_GCE_ZONE_US_EAST1_D + +endif # TERRAFORM_GCE_REGION_US_EAST1 + +if TERRAFORM_GCE_REGION_US_EAST4 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_EAST4_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_EAST4_A + bool "us-east4-a" + +config TERRAFORM_GCE_ZONE_US_EAST4_B + bool "us-east4-b" + +config TERRAFORM_GCE_ZONE_US_EAST4_C + bool "us-east4-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-east4-a" if TERRAFORM_GCE_ZONE_US_EAST4_A + default "us-east4-b" if TERRAFORM_GCE_ZONE_US_EAST4_B + default "us-east4-c" if TERRAFORM_GCE_ZONE_US_EAST4_C + +endif # TERRAFORM_GCE_REGION_US_EAST4 + +if TERRAFORM_GCE_REGION_US_EAST5 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_EAST5_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_EAST5_A + bool "us-east5-a" + +config TERRAFORM_GCE_ZONE_US_EAST5_B + bool "us-east5-b" + +config TERRAFORM_GCE_ZONE_US_EAST5_C + bool "us-east5-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-east5-a" if TERRAFORM_GCE_ZONE_US_EAST5_A + default "us-east5-b" if TERRAFORM_GCE_ZONE_US_EAST5_B + default "us-east5-c" if TERRAFORM_GCE_ZONE_US_EAST5_C + +endif # TERRAFORM_GCE_REGION_US_EAST5 + +if TERRAFORM_GCE_REGION_US_SOUTH1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_SOUTH1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_SOUTH1_A + bool "us-south1-a" + +config TERRAFORM_GCE_ZONE_US_SOUTH1_B + bool "us-south1-b" + +config TERRAFORM_GCE_ZONE_US_SOUTH1_C + bool "us-south1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-south1-a" if TERRAFORM_GCE_ZONE_US_SOUTH1_A + default "us-south1-b" if TERRAFORM_GCE_ZONE_US_SOUTH1_B + default "us-south1-c" if TERRAFORM_GCE_ZONE_US_SOUTH1_C + +endif # TERRAFORM_GCE_REGION_US_SOUTH1 + +if TERRAFORM_GCE_REGION_US_WEST1 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST1_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST1_A + bool "us-west1-a" + +config TERRAFORM_GCE_ZONE_US_WEST1_B + bool "us-west1-b" + +config TERRAFORM_GCE_ZONE_US_WEST1_C + bool "us-west1-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west1-a" if TERRAFORM_GCE_ZONE_US_WEST1_A + default "us-west1-b" if TERRAFORM_GCE_ZONE_US_WEST1_B + default "us-west1-c" if TERRAFORM_GCE_ZONE_US_WEST1_C + +endif # TERRAFORM_GCE_REGION_US_WEST1 + +if TERRAFORM_GCE_REGION_US_WEST2 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST2_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST2_A + bool "us-west2-a" + +config TERRAFORM_GCE_ZONE_US_WEST2_B + bool "us-west2-b" + +config TERRAFORM_GCE_ZONE_US_WEST2_C + bool "us-west2-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west2-a" if TERRAFORM_GCE_ZONE_US_WEST2_A + default "us-west2-b" if TERRAFORM_GCE_ZONE_US_WEST2_B + default "us-west2-c" if TERRAFORM_GCE_ZONE_US_WEST2_C + +endif # TERRAFORM_GCE_REGION_US_WEST2 + +if TERRAFORM_GCE_REGION_US_WEST3 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST3_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST3_A + bool "us-west3-a" + +config TERRAFORM_GCE_ZONE_US_WEST3_B + bool "us-west3-b" + +config TERRAFORM_GCE_ZONE_US_WEST3_C + bool "us-west3-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west3-a" if TERRAFORM_GCE_ZONE_US_WEST3_A + default "us-west3-b" if TERRAFORM_GCE_ZONE_US_WEST3_B + default "us-west3-c" if TERRAFORM_GCE_ZONE_US_WEST3_C + +endif # TERRAFORM_GCE_REGION_US_WEST3 + +if TERRAFORM_GCE_REGION_US_WEST4 + +choice + prompt "GCE zone" + default TERRAFORM_GCE_ZONE_US_WEST4_A + help + A zone is a deployment area within a region. + +config TERRAFORM_GCE_ZONE_US_WEST4_A + bool "us-west4-a" + +config TERRAFORM_GCE_ZONE_US_WEST4_B + bool "us-west4-b" + +config TERRAFORM_GCE_ZONE_US_WEST4_C + bool "us-west4-c" + +endchoice + +config TERRAFORM_GCE_ZONE + string + output yaml + default "us-west4-a" if TERRAFORM_GCE_ZONE_US_WEST4_A + default "us-west4-b" if TERRAFORM_GCE_ZONE_US_WEST4_B + default "us-west4-c" if TERRAFORM_GCE_ZONE_US_WEST4_C + +endif # TERRAFORM_GCE_REGION_US_WEST4 diff --git a/terraform/gce/kconfigs/Kconfig.machine b/terraform/gce/kconfigs/Kconfig.machine deleted file mode 100644 index 07e06233e..000000000 --- a/terraform/gce/kconfigs/Kconfig.machine +++ /dev/null @@ -1,995 +0,0 @@ -choice - prompt "GCE Machine Family" - default TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD - help - Select the family of platforms to choose from below. - -config TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD - bool "N1 Standard family" - depends on TARGET_ARCH_X86_64 - help - Balanced performance and cost-effectiveness. Intel - Haswell CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD - bool "N2 Standard family" - depends on TARGET_ARCH_X86_64 - help - General purpose computing on Intel Cascade Lake CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU - bool "N2 High CPU family" - depends on TARGET_ARCH_X86_64 - help - General purpose computing on Intel Cascade Lake CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD - bool "N2D Standard family" - depends on TARGET_ARCH_X86_64 - help - General purpose computing on AMD Milan CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU - bool "N2D High CPU family" - depends on TARGET_ARCH_X86_64 - help - General purpose computing on AMD Milan CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD - bool "N4 Standard family" - depends on TARGET_ARCH_X86_64 - help - General purpose computing on Intel Emerald Rapids CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU - bool "N4 High CPU family" - depends on TARGET_ARCH_X86_64 - help - General purpose computing on Intel Emerald Rapids CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU - bool "E2 High CPU family" - depends on TARGET_ARCH_X86_64 - help - Cost-effective computing on Intel/AMD EPYC processors. - -config TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD - bool "E2 Standard family" - depends on TARGET_ARCH_X86_64 - help - Cost-effective computing on Intel/AMD EPYC processors. - -config TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU - bool "N1 High CPU family" - depends on TARGET_ARCH_X86_64 - help - Balanced performance and cost-effectiveness. Intel CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD - bool "C3 Standard family" - depends on TARGET_ARCH_X86_64 - help - High performance on Intel Sapphire Rapids CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD - bool "C3D Standard family" - depends on TARGET_ARCH_X86_64 - help - High performance on AMD EPYC Genoa CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD - bool "C4 Standard family" - depends on TARGET_ARCH_X86_64 - help - Consistently high performance on Intel Emerald Rapids CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD - bool "C4A Standard family" - depends on TARGET_ARCH_ARM64 - help - High performance on Google Axion Arm-based processors. - -config TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD - bool "C4D Standard family" - depends on TARGET_ARCH_X86_64 - help - High performance on AMD EPYC Turin CPUs. - -config TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU - bool "A2 High GPU family" - depends on TARGET_ARCH_X86_64 - help - GPU-accelerated computing with NVIDIA A100 GPUs. - -endchoice - -if TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 - help - The E2 machine series offers both Intel and AMD EPYC - processors, selected for you at the time of VM creation. - Machine types in this series are available in all regions - and zones and support a virtio memory balloon device. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 - bool "e2-highcpu-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 2GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 - bool "e2-highcpu-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 - bool "e2-highcpu-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 - bool "e2-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 - bool "e2-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 32GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "e2-highcpu-2" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 - default "e2-highcpu-4" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 - default "e2-highcpu-8" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 - default "e2-highcpu-16" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 - default "e2-highcpu-32" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU - -if TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_E2_STANDARD_8 - help - The E2 machine series offers both Intel and AMD EPYC - processors, selected for you at the time of VM creation. - Machine types in this series are available in all regions - and zones and support a virtio memory balloon device. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_2 - bool "e2-standard-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_4 - bool "e2-standard-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_8 - bool "e2-standard-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_16 - bool "e2-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_E2_STANDARD_32 - bool "e2-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "e2-standard-2" if TERRAFORM_GCE_MACHINE_E2_STANDARD_2 - default "e2-standard-4" if TERRAFORM_GCE_MACHINE_E2_STANDARD_4 - default "e2-standard-8" if TERRAFORM_GCE_MACHINE_E2_STANDARD_8 - default "e2-standard-16" if TERRAFORM_GCE_MACHINE_E2_STANDARD_16 - default "e2-standard-32" if TERRAFORM_GCE_MACHINE_E2_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N1_STANDARD_8 - help - The N1 machine series is Compute Engine's first generation - general-purpose machine series available on Intel Skylake, - Broadwell, Haswell, Sandy Bridge, and Ivy Bridge CPU - platforms. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_1 - bool "n1-standard-1" - help - 1 vCPU and 3.75GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_2 - bool "n1-standard-2" - help - 2 vCPUs (1 core) and 7.5GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_4 - bool "n1-standard-4" - help - 4 vCPUs (2 cores) and 15GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_8 - bool "n1-standard-8" - help - 8 vCPUs (4 cores) and 30GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_16 - bool "n1-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 60GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_STANDARD_32 - bool "n1-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 120GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n1-standard-1" if TERRAFORM_GCE_MACHINE_N1_STANDARD_1 - default "n1-standard-2" if TERRAFORM_GCE_MACHINE_N1_STANDARD_2 - default "n1-standard-4" if TERRAFORM_GCE_MACHINE_N1_STANDARD_4 - default "n1-standard-8" if TERRAFORM_GCE_MACHINE_N1_STANDARD_8 - default "n1-standard-16" if TERRAFORM_GCE_MACHINE_N1_STANDARD_16 - default "n1-standard-32" if TERRAFORM_GCE_MACHINE_N1_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 - help - The N1 machine series is Compute Engine's first generation - general-purpose machine series available on Intel Skylake, - Broadwell, Haswell, Sandy Bridge, and Ivy Bridge CPU - platforms. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 - bool "n1-highcpu-2" - help - 2 vCPUs (1 core) and 1.8GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 - bool "n1-highcpu-4" - help - 4 vCPUs (2 cores) and 3.6GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 - bool "n1-highcpu-8" - help - 8 vCPUs (4 cores) and 7.2GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 - bool "n1-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 14.4GB of memory. - -config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 - bool "n1-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 28.8GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n1-highcpu-2" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 - default "n1-highcpu-4" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 - default "n1-highcpu-8" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 - default "n1-highcpu-16" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 - default "n1-highcpu-32" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU - -if TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2_STANDARD_8 - help - The N2 machine series can run on either Intel Cascade Lake - (on smaller configurations) or Intel Ice Lake. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_2 - bool "n2-standard-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_4 - bool "n2-standard-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_8 - bool "n2-standard-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_16 - bool "n2-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_STANDARD_32 - bool "n2-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2-standard-2" if TERRAFORM_GCE_MACHINE_N2_STANDARD_2 - default "n2-standard-4" if TERRAFORM_GCE_MACHINE_N2_STANDARD_4 - default "n2-standard-8" if TERRAFORM_GCE_MACHINE_N2_STANDARD_8 - default "n2-standard-16" if TERRAFORM_GCE_MACHINE_N2_STANDARD_16 - default "n2-standard-32" if TERRAFORM_GCE_MACHINE_N2_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 - help - The N2 machine series can run on either Intel Cascade Lake - (on smaller configurations) or Intel Ice Lake. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 - bool "n2-highcpu-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 2GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 - bool "n2-highcpu-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 - bool "n2-highcpu-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 - bool "n2-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 - bool "n2-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 32GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2-highcpu-2" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 - default "n2-highcpu-4" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 - default "n2-highcpu-8" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 - default "n2-highcpu-16" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 - default "n2-highcpu-32" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU - -if TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 - help - The N2D machine series can run on either AMD EPYC Milan or - AMD EPYC Rome processors. The third generation AMD EPYC - Milan processor is available only in specific regions and zones. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 - bool "n2d-standard-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 - bool "n2d-standard-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 - bool "n2d-standard-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 - bool "n2d-standard-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 - bool "n2d-standard-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2d-standard-2" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 - default "n2d-standard-4" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 - default "n2d-standard-8" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 - default "n2d-standard-16" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 - default "n2d-standard-32" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU - -choice - prompt "GCE Machine type" - default TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 - help - The N2D machine series can run on either AMD EPYC Milan or - AMD EPYC Rome processors. The third generation AMD EPYC - Milan processor is available only in specific regions and zones. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 - bool "n2d-highcpu-2" - depends on TARGET_ARCH_X86_64 - help - 2 vCPUs (1 core) and 2GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 - bool "n2d-highcpu-4" - depends on TARGET_ARCH_X86_64 - help - 4 vCPUs (2 cores) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 - bool "n2d-highcpu-8" - depends on TARGET_ARCH_X86_64 - help - 8 vCPUs (4 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 - bool "n2d-highcpu-16" - depends on TARGET_ARCH_X86_64 - help - 16 vCPUs (8 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 - bool "n2d-highcpu-32" - depends on TARGET_ARCH_X86_64 - help - 32 vCPUs (16 cores) and 32GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n2d-highcpu-2" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 - default "n2d-highcpu-4" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 - default "n2d-highcpu-8" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 - default "n2d-highcpu-16" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 - default "n2d-highcpu-32" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU - -if TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_N4_STANDARD_4 - help - N4 VMs are powered by the 5th generation Intel Xeon Scalable - processors (code-named Emerald Rapids) and Titanium. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_2 - bool "n4-standard-2" - help - 2 vCPUs (1 core) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_4 - bool "n4-standard-4" - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_8 - bool "n4-standard-8" - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_16 - bool "n4-standard-16" - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_STANDARD_32 - bool "n4-standard-32" - help - 32 vCPUs (16 cores) and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n4-standard-2" if TERRAFORM_GCE_MACHINE_N4_STANDARD_2 - default "n4-standard-4" if TERRAFORM_GCE_MACHINE_N4_STANDARD_4 - default "n4-standard-8" if TERRAFORM_GCE_MACHINE_N4_STANDARD_8 - default "n4-standard-16" if TERRAFORM_GCE_MACHINE_N4_STANDARD_16 - default "n4-standard-32" if TERRAFORM_GCE_MACHINE_N4_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N4_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 - help - N4 VMs are powered by the 5th generation Intel Xeon Scalable - processors (code-named Emerald Rapids) and Titanium. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_2 - bool "n4-highcpu-2" - help - 2 vCPUs (1 core) and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 - bool "n4-highcpu-4" - help - 4 vCPUs (2 cores) and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_8 - bool "n4-highcpu-8" - help - 8 vCPUs (4 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_16 - bool "n4-highcpu-16" - help - 16 vCPUs (8 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_N4_HIGHCPU_32 - bool "n4-highcpu-32" - help - 32 vCPUs (16 cores) and 64GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "n4-highcpu-2" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_2 - default "n4-highcpu-4" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_4 - default "n4-highcpu-8" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_8 - default "n4-highcpu-16" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_16 - default "n4-highcpu-32" if TERRAFORM_GCE_MACHINE_N4_HIGHCPU_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_N4_HIGHCPU - -if TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C3_STANDARD_4 - help - C3 VMs are powered by the 4th generation Intel Xeon - Scalable processors (code-named Sapphire Rapids), DDR5 - memory, and Titanium, enabling higher levels of networking - performance, isolation and security. - -config TERRAFORM_GCE_MACHINE_C3_STANDARD_4 - bool "c3-standard-4" - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_C3_STANDARD_8 - bool "c3-standard-8" - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_C3_STANDARD_22 - bool "c3-standard-22" - help - 22 vCPUs (11 cores) and 88GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c3-standard-4" if TERRAFORM_GCE_MACHINE_C3_STANDARD_4 - default "c3-standard-8" if TERRAFORM_GCE_MACHINE_C3_STANDARD_8 - default "c3-standard-22" if TERRAFORM_GCE_MACHINE_C3_STANDARD_22 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 - help - C3D VMs are powered by the 4th-gen AMD EPYC (Genoa) - processor. C3D uses Titanium, enabling higher levels - of networking performance, isolation and security. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 - bool "c3d-standard-4" - help - 4 vCPUs (2 cores) and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_8 - bool "c3d-standard-8" - help - 8 vCPUs (4 cores) and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_16 - bool "c3d-standard-16" - help - 16 vCPUs (8 cores) and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_C3D_STANDARD_30 - bool "c3d-standard-30" - help - 30 vCPUs (15 cores) and 120GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c3d-standard-4" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_4 - default "c3d-standard-8" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_8 - default "c3d-standard-16" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_16 - default "c3d-standard-30" if TERRAFORM_GCE_MACHINE_C3D_STANDARD_30 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C3D_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C4_STANDARD_4 - help - C4 VMs are powered by 6th generation (code-named Granite - Rapids) or 5th generation (code-named Emerald Rapids) - Intel Xeon Scalable processors and Titanium. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_2 - bool "c4-standard-2" - help - 2 vCPUs (1 core) and 7GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_4 - bool "c4-standard-4" - help - 4 vCPUs (2 cores) and 15GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_8 - bool "c4-standard-8" - help - 8 vCPUs (4 cores) and 30GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_16 - bool "c4-standard-16" - help - 16 vCPUs (8 cores) and 60GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_24 - bool "c4-standard-24" - help - 24 vCPUs (12 cores) and 90GB of memory. - -config TERRAFORM_GCE_MACHINE_C4_STANDARD_32 - bool "c4-standard-32" - help - 32 vCPUs (16 cores) and 120GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c4-standard-2" if TERRAFORM_GCE_MACHINE_C4_STANDARD_2 - default "c4-standard-4" if TERRAFORM_GCE_MACHINE_C4_STANDARD_4 - default "c4-standard-8" if TERRAFORM_GCE_MACHINE_C4_STANDARD_8 - default "c4-standard-16" if TERRAFORM_GCE_MACHINE_C4_STANDARD_16 - default "c4-standard-24" if TERRAFORM_GCE_MACHINE_C4_STANDARD_24 - default "c4-standard-32" if TERRAFORM_GCE_MACHINE_C4_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 - help - C4A VMs are powered by Google's first Arm-based Axion™ - processor, DDR5 memory, and local Titanium SSDs. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 - bool "c4a-standard-1" - help - 1 vCPU and 4GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 - bool "c4a-standard-2" - help - 2 vCPUs and 8GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 - bool "c4a-standard-4" - help - 4 vCPUs and 16GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 - bool "c4a-standard-8" - help - 8 vCPUs and 32GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 - bool "c4a-standard-16" - help - 16 vCPUs and 64GB of memory. - -config TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 - bool "c4a-standard-32" - help - 32 vCPUs and 128GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c4a-standard-1" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 - default "c4a-standard-2" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 - default "c4a-standard-4" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 - default "c4a-standard-8" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 - default "c4a-standard-16" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 - default "c4a-standard-32" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 - help - C4D VMs are powered by the fifth generation AMD EPYC Turin - processor and Titanium. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_2 - bool "c4d-standard-2" - help - 2 vCPUs (1 core) and 7GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 - bool "c4d-standard-4" - help - 4 vCPUs (2 cores) and 15GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_8 - bool "c4d-standard-8" - help - 8 vCPUs (4 cores) and 31GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_16 - bool "c4d-standard-16" - help - 16 vCPUs (8 cores) and 62GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_24 - bool "c4d-standard-24" - help - 24 vCPUs (12 cores) and 93GB of memory. - -config TERRAFORM_GCE_MACHINE_C4D_STANDARD_32 - bool "c4d-standard-32" - help - 32 vCPUs (16 cores) and 124GB of memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "c4d-standard-2" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_2 - default "c4d-standard-4" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_4 - default "c4d-standard-8" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_8 - default "c4d-standard-16" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_16 - default "c4d-standard-24" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_24 - default "c4d-standard-32" if TERRAFORM_GCE_MACHINE_C4D_STANDARD_32 - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "hyperdisk-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_C4D_STANDARD - -if TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU - -choice - prompt "GCE Machine Type" - default TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G - help - A2 High GPU machine types have a fixed number of A100 - 40GB GPUs. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G - bool "a2-highgpu-1g" - help - 12 vCPUs, 85GB of memory, and 1 GPU with 40GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_2G - bool "a2-highgpu-2g" - help - 24 vCPUs, 170GB of memory, and 2 GPUs with 80GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_4G - bool "a2-highgpu-4g" - help - 48 vCPUs, 340GB of memory, and 4 GPUs with 160GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_8G - bool "a2-highgpu-8g" - help - 96 vCPUs, 680GB of memory, and 8 GPUs with 320GB of GPU - memory. - -config TERRAFORM_GCE_MACHINE_A2_HIGHGPU_16G - bool "a2-highgpu-16g" - help - 96 vCPUs, 1360GB of memory, and 16 GPUs with 640GB of GPU - memory. - -endchoice - -config TERRAFORM_GCE_MACHINE_TYPE - string - output yaml - default "a2-highgpu-1g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_1G - default "a2-highgpu-2g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_2G - default "a2-highgpu-4g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_4G - default "a2-highgpu-8g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_8G - default "a2-highgpu-16g" if TERRAFORM_GCE_MACHINE_A2_HIGHGPU_16G - -config TERRAFORM_GCE_IMAGE_TYPE - string - output yaml - default "pd-balanced" - -endif # TERRAFORM_GCE_MACHINE_FAMILY_A2_HIGHGPU diff --git a/terraform/gce/kconfigs/Kconfig.machine.default b/terraform/gce/kconfigs/Kconfig.machine.default new file mode 100644 index 000000000..f781f7803 --- /dev/null +++ b/terraform/gce/kconfigs/Kconfig.machine.default @@ -0,0 +1,2496 @@ +# GCE Machine Type Selection +# This file is auto-generated. Do not edit manually. +# Generated by: terraform/gce/scripts/gen_kconfig_machine + +choice + prompt "GCE Machine Family" + default TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD + help + Select the family of platforms to choose from below. + + Machine types are organized by series, which combines the + generation (e.g., n2, c3) with the workload type (e.g., + standard, highcpu, highmem). + + Machine type availability varies by region and zone. You can + verify available types for your zone using: + + gcloud compute machine-types list --zones= + + For detailed information about GCE machine families: + + https://cloud.google.com/compute/docs/machine-types + +config TERRAFORM_GCE_MACHINE_FAMILY_C2_STANDARD + bool "C2 Standard" + depends on TARGET_ARCH_X86_64 + help + Compute-optimized with 3.8 GHz sustained all-core turbo on Intel Cascade Lake. + + This series contains 5 machine types: + - vCPUs: 4-60 + - Memory: 16.0-240.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C2D_HIGHCPU + bool "C2D High CPU" + depends on TARGET_ARCH_X86_64 + help + Compute-optimized high CPU with AMD EPYC Milan processors. + + This series contains 7 machine types: + - vCPUs: 2-112 + - Memory: 4.0-224.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C2D_HIGHMEM + bool "C2D High Memory" + depends on TARGET_ARCH_X86_64 + help + Compute-optimized high memory with AMD EPYC Milan processors. + + This series contains 7 machine types: + - vCPUs: 2-112 + - Memory: 16.0-896.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C2D_STANDARD + bool "C2D Standard" + depends on TARGET_ARCH_X86_64 + help + Compute-optimized balanced with AMD EPYC Milan processors. + + This series contains 7 machine types: + - vCPUs: 2-112 + - Memory: 8.0-448.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C3_HIGHCPU + bool "C3 High CPU" + depends on TARGET_ARCH_X86_64 + help + Third generation compute-optimized high CPU with Intel Sapphire Rapids. + + This series contains 6 machine types: + - vCPUs: 4-176 + - Memory: 8.0-352.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD + bool "C3 Standard" + depends on TARGET_ARCH_X86_64 + help + Third generation compute-optimized balanced with Intel Sapphire Rapids. + + This series contains 6 machine types: + - vCPUs: 4-176 + - Memory: 16.0-704.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C3D_HIGHCPU + bool "C3D High CPU" + depends on TARGET_ARCH_X86_64 + help + Third generation compute-optimized high CPU with AMD EPYC Genoa. + + This series contains 8 machine types: + - vCPUs: 4-360 + - Memory: 8.0-708.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C4_HIGHCPU + bool "C4 High CPU" + depends on TARGET_ARCH_X86_64 + help + Fourth generation compute-optimized high CPU with Intel Emerald Rapids. + + This series contains 9 machine types: + - vCPUs: 2-192 + - Memory: 4.0-384.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD + bool "C4 Standard" + depends on TARGET_ARCH_X86_64 + help + Fourth generation compute-optimized balanced with Intel Emerald Rapids. + + This series contains 9 machine types: + - vCPUs: 2-192 + - Memory: 7.0-720.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C4A_HIGHCPU + bool "C4A High CPU" + depends on TARGET_ARCH_ARM64 + help + Fourth generation compute-optimized high CPU with Arm-based Axion processors. + + This series contains 9 machine types: + - vCPUs: 1-72 + - Memory: 2.0-144.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C4A_HIGHMEM + bool "C4A High Memory" + depends on TARGET_ARCH_ARM64 + help + Fourth generation compute-optimized high memory with Arm-based Axion processors. + + This series contains 16 machine types: + - vCPUs: 1-72 + - Memory: 8.0-576.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD + bool "C4A Standard" + depends on TARGET_ARCH_ARM64 + help + Fourth generation compute-optimized balanced with Arm-based Axion processors. + + This series contains 16 machine types: + - vCPUs: 1-72 + - Memory: 4.0-288.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU + bool "E2 High CPU" + depends on TARGET_ARCH_X86_64 + help + Cost-optimized compute-intensive on Intel or AMD processors. + + This series contains 5 machine types: + - vCPUs: 2-32 + - Memory: 2.0-32.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHMEM + bool "E2 High Memory" + depends on TARGET_ARCH_X86_64 + help + Cost-optimized memory-intensive on Intel or AMD processors. + + This series contains 4 machine types: + - vCPUs: 2-16 + - Memory: 16.0-128.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_MEDIUM + bool "E2 Medium" + depends on TARGET_ARCH_X86_64 + help + Cost-optimized shared-core machine with 2 vCPUs and 4 GB memory. + + This series contains 1 machine type: + - vCPUs: 2-2 + - Memory: 4.0-4.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_MICRO + bool "E2 Micro" + depends on TARGET_ARCH_X86_64 + help + Cost-optimized shared-core machine with 2 vCPUs and 1 GB memory. + + This series contains 1 machine type: + - vCPUs: 2-2 + - Memory: 1.0-1.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_SMALL + bool "E2 Small" + depends on TARGET_ARCH_X86_64 + help + Cost-optimized shared-core machine with 2 vCPUs and 2 GB memory. + + This series contains 1 machine type: + - vCPUs: 2-2 + - Memory: 2.0-2.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD + bool "E2 Standard" + depends on TARGET_ARCH_X86_64 + help + Cost-optimized balanced on Intel or AMD processors. + + This series contains 5 machine types: + - vCPUs: 2-32 + - Memory: 8.0-128.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_F1_MICRO + bool "F1 Micro" + depends on TARGET_ARCH_X86_64 + help + Legacy shared-core machine type. Consider using e2-micro instead. + + This series contains 1 machine type: + - vCPUs: 1-1 + - Memory: 0.6-0.6GB + +config TERRAFORM_GCE_MACHINE_FAMILY_G1_SMALL + bool "G1 Small" + depends on TARGET_ARCH_X86_64 + help + Legacy shared-core machine type. Consider using e2-small instead. + + This series contains 1 machine type: + - vCPUs: 1-1 + - Memory: 1.7-1.7GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU + bool "N1 High CPU" + depends on TARGET_ARCH_X86_64 + help + First generation compute-intensive on Intel Haswell/Broadwell/Skylake. + + This series contains 7 machine types: + - vCPUs: 2-96 + - Memory: 1.8-86.4GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHMEM + bool "N1 High Memory" + depends on TARGET_ARCH_X86_64 + help + First generation memory-intensive on Intel Haswell/Broadwell/Skylake. + + This series contains 7 machine types: + - vCPUs: 2-96 + - Memory: 13.0-624.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD + bool "N1 Standard" + depends on TARGET_ARCH_X86_64 + help + First generation balanced on Intel Haswell/Broadwell/Skylake. + + This series contains 8 machine types: + - vCPUs: 1-96 + - Memory: 3.8-360.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU + bool "N2 High CPU" + depends on TARGET_ARCH_X86_64 + help + Second generation compute-intensive on Intel Cascade Lake or Ice Lake. + + This series contains 9 machine types: + - vCPUs: 2-96 + - Memory: 2.0-96.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHMEM + bool "N2 High Memory" + depends on TARGET_ARCH_X86_64 + help + Second generation memory-intensive on Intel Cascade Lake or Ice Lake. + + This series contains 10 machine types: + - vCPUs: 2-128 + - Memory: 16.0-864.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD + bool "N2 Standard" + depends on TARGET_ARCH_X86_64 + help + Second generation balanced on Intel Cascade Lake or Ice Lake. + + This series contains 10 machine types: + - vCPUs: 2-128 + - Memory: 8.0-512.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU + bool "N2D High CPU" + depends on TARGET_ARCH_X86_64 + help + Second generation compute-intensive on AMD EPYC Rome or Milan. + + This series contains 11 machine types: + - vCPUs: 2-224 + - Memory: 2.0-224.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHMEM + bool "N2D High Memory" + depends on TARGET_ARCH_X86_64 + help + Second generation memory-intensive on AMD EPYC Rome or Milan. + + This series contains 9 machine types: + - vCPUs: 2-96 + - Memory: 16.0-768.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD + bool "N2D Standard" + depends on TARGET_ARCH_X86_64 + help + Second generation balanced on AMD EPYC Rome or Milan. + + This series contains 11 machine types: + - vCPUs: 2-224 + - Memory: 8.0-896.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_T2D_STANDARD + bool "T2D Standard" + depends on TARGET_ARCH_X86_64 + help + Scale-out optimized on AMD EPYC Milan. Good for web and containerized workloads. + + This series contains 8 machine types: + - vCPUs: 1-60 + - Memory: 4.0-240.0GB + +config TERRAFORM_GCE_MACHINE_FAMILY_Z3_HIGHMEM + bool "Z3 High Memory" + depends on TARGET_ARCH_X86_64 + help + Storage-optimized with large local SSD capacity for databases and analytics. + + This series contains 1 machine type: + - vCPUs: 192-192 + - Memory: 1536.0-1536.0GB + +endchoice + +if TERRAFORM_GCE_MACHINE_FAMILY_C2_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C2_STANDARD_4 + help + Compute-optimized with 3.8 GHz sustained all-core turbo on Intel Cascade Lake. + +config TERRAFORM_GCE_MACHINE_C2_STANDARD_4 + bool "c2-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C2_STANDARD_8 + bool "c2-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C2_STANDARD_16 + bool "c2-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C2_STANDARD_30 + bool "c2-standard-30" + depends on TARGET_ARCH_X86_64 + help + 30 vCPUs (15 cores) and 120GB of memory. + +config TERRAFORM_GCE_MACHINE_C2_STANDARD_60 + bool "c2-standard-60" + depends on TARGET_ARCH_X86_64 + help + 60 vCPUs (30 cores) and 240GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c2-standard-4" if TERRAFORM_GCE_MACHINE_C2_STANDARD_4 + default "c2-standard-8" if TERRAFORM_GCE_MACHINE_C2_STANDARD_8 + default "c2-standard-16" if TERRAFORM_GCE_MACHINE_C2_STANDARD_16 + default "c2-standard-30" if TERRAFORM_GCE_MACHINE_C2_STANDARD_30 + default "c2-standard-60" if TERRAFORM_GCE_MACHINE_C2_STANDARD_60 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C2_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C2D_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_2 + help + Compute-optimized high CPU with AMD EPYC Milan processors. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_2 + bool "c2d-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_4 + bool "c2d-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_8 + bool "c2d-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_16 + bool "c2d-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_32 + bool "c2d-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_56 + bool "c2d-highcpu-56" + depends on TARGET_ARCH_X86_64 + help + 56 vCPUs (28 cores) and 112GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_112 + bool "c2d-highcpu-112" + depends on TARGET_ARCH_X86_64 + help + 112 vCPUs (56 cores) and 224GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c2d-highcpu-2" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_2 + default "c2d-highcpu-4" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_4 + default "c2d-highcpu-8" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_8 + default "c2d-highcpu-16" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_16 + default "c2d-highcpu-32" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_32 + default "c2d-highcpu-56" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_56 + default "c2d-highcpu-112" if TERRAFORM_GCE_MACHINE_C2D_HIGHCPU_112 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C2D_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_C2D_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_2 + help + Compute-optimized high memory with AMD EPYC Milan processors. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_2 + bool "c2d-highmem-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_4 + bool "c2d-highmem-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_8 + bool "c2d-highmem-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_16 + bool "c2d-highmem-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_32 + bool "c2d-highmem-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_56 + bool "c2d-highmem-56" + depends on TARGET_ARCH_X86_64 + help + 56 vCPUs (28 cores) and 448GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_112 + bool "c2d-highmem-112" + depends on TARGET_ARCH_X86_64 + help + 112 vCPUs (56 cores) and 896GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c2d-highmem-2" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_2 + default "c2d-highmem-4" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_4 + default "c2d-highmem-8" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_8 + default "c2d-highmem-16" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_16 + default "c2d-highmem-32" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_32 + default "c2d-highmem-56" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_56 + default "c2d-highmem-112" if TERRAFORM_GCE_MACHINE_C2D_HIGHMEM_112 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C2D_HIGHMEM + +if TERRAFORM_GCE_MACHINE_FAMILY_C2D_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C2D_STANDARD_2 + help + Compute-optimized balanced with AMD EPYC Milan processors. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_2 + bool "c2d-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_4 + bool "c2d-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_8 + bool "c2d-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_16 + bool "c2d-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_32 + bool "c2d-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_56 + bool "c2d-standard-56" + depends on TARGET_ARCH_X86_64 + help + 56 vCPUs (28 cores) and 224GB of memory. + +config TERRAFORM_GCE_MACHINE_C2D_STANDARD_112 + bool "c2d-standard-112" + depends on TARGET_ARCH_X86_64 + help + 112 vCPUs (56 cores) and 448GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c2d-standard-2" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_2 + default "c2d-standard-4" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_4 + default "c2d-standard-8" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_8 + default "c2d-standard-16" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_16 + default "c2d-standard-32" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_32 + default "c2d-standard-56" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_56 + default "c2d-standard-112" if TERRAFORM_GCE_MACHINE_C2D_STANDARD_112 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C2D_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C3_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C3_HIGHCPU_4 + help + Third generation compute-optimized high CPU with Intel Sapphire Rapids. + +config TERRAFORM_GCE_MACHINE_C3_HIGHCPU_4 + bool "c3-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_HIGHCPU_8 + bool "c3-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_HIGHCPU_22 + bool "c3-highcpu-22" + depends on TARGET_ARCH_X86_64 + help + 22 vCPUs (11 cores) and 44GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_HIGHCPU_44 + bool "c3-highcpu-44" + depends on TARGET_ARCH_X86_64 + help + 44 vCPUs (22 cores) and 88GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_HIGHCPU_88 + bool "c3-highcpu-88" + depends on TARGET_ARCH_X86_64 + help + 88 vCPUs (44 cores) and 176GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_HIGHCPU_176 + bool "c3-highcpu-176" + depends on TARGET_ARCH_X86_64 + help + 176 vCPUs (88 cores) and 352GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c3-highcpu-4" if TERRAFORM_GCE_MACHINE_C3_HIGHCPU_4 + default "c3-highcpu-8" if TERRAFORM_GCE_MACHINE_C3_HIGHCPU_8 + default "c3-highcpu-22" if TERRAFORM_GCE_MACHINE_C3_HIGHCPU_22 + default "c3-highcpu-44" if TERRAFORM_GCE_MACHINE_C3_HIGHCPU_44 + default "c3-highcpu-88" if TERRAFORM_GCE_MACHINE_C3_HIGHCPU_88 + default "c3-highcpu-176" if TERRAFORM_GCE_MACHINE_C3_HIGHCPU_176 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C3_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C3_STANDARD_4 + help + Third generation compute-optimized balanced with Intel Sapphire Rapids. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_4 + bool "c3-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_8 + bool "c3-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_22 + bool "c3-standard-22" + depends on TARGET_ARCH_X86_64 + help + 22 vCPUs (11 cores) and 88GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_44 + bool "c3-standard-44" + depends on TARGET_ARCH_X86_64 + help + 44 vCPUs (22 cores) and 176GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_88 + bool "c3-standard-88" + depends on TARGET_ARCH_X86_64 + help + 88 vCPUs (44 cores) and 352GB of memory. + +config TERRAFORM_GCE_MACHINE_C3_STANDARD_176 + bool "c3-standard-176" + depends on TARGET_ARCH_X86_64 + help + 176 vCPUs (88 cores) and 704GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c3-standard-4" if TERRAFORM_GCE_MACHINE_C3_STANDARD_4 + default "c3-standard-8" if TERRAFORM_GCE_MACHINE_C3_STANDARD_8 + default "c3-standard-22" if TERRAFORM_GCE_MACHINE_C3_STANDARD_22 + default "c3-standard-44" if TERRAFORM_GCE_MACHINE_C3_STANDARD_44 + default "c3-standard-88" if TERRAFORM_GCE_MACHINE_C3_STANDARD_88 + default "c3-standard-176" if TERRAFORM_GCE_MACHINE_C3_STANDARD_176 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C3_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C3D_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_4 + help + Third generation compute-optimized high CPU with AMD EPYC Genoa. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_4 + bool "c3d-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_8 + bool "c3d-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_16 + bool "c3d-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_30 + bool "c3d-highcpu-30" + depends on TARGET_ARCH_X86_64 + help + 30 vCPUs (15 cores) and 59GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_60 + bool "c3d-highcpu-60" + depends on TARGET_ARCH_X86_64 + help + 60 vCPUs (30 cores) and 118GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_90 + bool "c3d-highcpu-90" + depends on TARGET_ARCH_X86_64 + help + 90 vCPUs (45 cores) and 177GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_180 + bool "c3d-highcpu-180" + depends on TARGET_ARCH_X86_64 + help + 180 vCPUs (90 cores) and 354GB of memory. + +config TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_360 + bool "c3d-highcpu-360" + depends on TARGET_ARCH_X86_64 + help + 360 vCPUs (180 cores) and 708GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c3d-highcpu-4" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_4 + default "c3d-highcpu-8" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_8 + default "c3d-highcpu-16" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_16 + default "c3d-highcpu-30" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_30 + default "c3d-highcpu-60" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_60 + default "c3d-highcpu-90" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_90 + default "c3d-highcpu-180" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_180 + default "c3d-highcpu-360" if TERRAFORM_GCE_MACHINE_C3D_HIGHCPU_360 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C3D_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_C4_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C4_HIGHCPU_2 + help + Fourth generation compute-optimized high CPU with Intel Emerald Rapids. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_2 + bool "c4-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_4 + bool "c4-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_8 + bool "c4-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_16 + bool "c4-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_24 + bool "c4-highcpu-24" + depends on TARGET_ARCH_X86_64 + help + 24 vCPUs (12 cores) and 48GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_32 + bool "c4-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_48 + bool "c4-highcpu-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 96GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_96 + bool "c4-highcpu-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 192GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_HIGHCPU_192 + bool "c4-highcpu-192" + depends on TARGET_ARCH_X86_64 + help + 192 vCPUs (96 cores) and 384GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4-highcpu-2" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_2 + default "c4-highcpu-4" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_4 + default "c4-highcpu-8" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_8 + default "c4-highcpu-16" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_16 + default "c4-highcpu-24" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_24 + default "c4-highcpu-32" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_32 + default "c4-highcpu-48" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_48 + default "c4-highcpu-96" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_96 + default "c4-highcpu-192" if TERRAFORM_GCE_MACHINE_C4_HIGHCPU_192 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C4_STANDARD_2 + help + Fourth generation compute-optimized balanced with Intel Emerald Rapids. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_2 + bool "c4-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 7GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_4 + bool "c4-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 15GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_8 + bool "c4-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 30GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_16 + bool "c4-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 60GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_24 + bool "c4-standard-24" + depends on TARGET_ARCH_X86_64 + help + 24 vCPUs (12 cores) and 90GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_32 + bool "c4-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 120GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_48 + bool "c4-standard-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 180GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_96 + bool "c4-standard-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 360GB of memory. + +config TERRAFORM_GCE_MACHINE_C4_STANDARD_192 + bool "c4-standard-192" + depends on TARGET_ARCH_X86_64 + help + 192 vCPUs (96 cores) and 720GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4-standard-2" if TERRAFORM_GCE_MACHINE_C4_STANDARD_2 + default "c4-standard-4" if TERRAFORM_GCE_MACHINE_C4_STANDARD_4 + default "c4-standard-8" if TERRAFORM_GCE_MACHINE_C4_STANDARD_8 + default "c4-standard-16" if TERRAFORM_GCE_MACHINE_C4_STANDARD_16 + default "c4-standard-24" if TERRAFORM_GCE_MACHINE_C4_STANDARD_24 + default "c4-standard-32" if TERRAFORM_GCE_MACHINE_C4_STANDARD_32 + default "c4-standard-48" if TERRAFORM_GCE_MACHINE_C4_STANDARD_48 + default "c4-standard-96" if TERRAFORM_GCE_MACHINE_C4_STANDARD_96 + default "c4-standard-192" if TERRAFORM_GCE_MACHINE_C4_STANDARD_192 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_C4A_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_1 + help + Fourth generation compute-optimized high CPU with Arm-based Axion processors. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_1 + bool "c4a-highcpu-1" + depends on TARGET_ARCH_ARM64 + help + 1 vCPU and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_2 + bool "c4a-highcpu-2" + depends on TARGET_ARCH_ARM64 + help + 2 vCPUs (1 core) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_4 + bool "c4a-highcpu-4" + depends on TARGET_ARCH_ARM64 + help + 4 vCPUs (2 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_8 + bool "c4a-highcpu-8" + depends on TARGET_ARCH_ARM64 + help + 8 vCPUs (4 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_16 + bool "c4a-highcpu-16" + depends on TARGET_ARCH_ARM64 + help + 16 vCPUs (8 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_32 + bool "c4a-highcpu-32" + depends on TARGET_ARCH_ARM64 + help + 32 vCPUs (16 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_48 + bool "c4a-highcpu-48" + depends on TARGET_ARCH_ARM64 + help + 48 vCPUs (24 cores) and 96GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_64 + bool "c4a-highcpu-64" + depends on TARGET_ARCH_ARM64 + help + 64 vCPUs (32 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_72 + bool "c4a-highcpu-72" + depends on TARGET_ARCH_ARM64 + help + 72 vCPUs (36 cores) and 144GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4a-highcpu-1" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_1 + default "c4a-highcpu-2" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_2 + default "c4a-highcpu-4" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_4 + default "c4a-highcpu-8" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_8 + default "c4a-highcpu-16" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_16 + default "c4a-highcpu-32" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_32 + default "c4a-highcpu-48" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_48 + default "c4a-highcpu-64" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_64 + default "c4a-highcpu-72" if TERRAFORM_GCE_MACHINE_C4A_HIGHCPU_72 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4A_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_C4A_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_1 + help + Fourth generation compute-optimized high memory with Arm-based Axion processors. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_1 + bool "c4a-highmem-1" + depends on TARGET_ARCH_ARM64 + help + 1 vCPU and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_2 + bool "c4a-highmem-2" + depends on TARGET_ARCH_ARM64 + help + 2 vCPUs (1 core) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_4 + bool "c4a-highmem-4" + depends on TARGET_ARCH_ARM64 + help + 4 vCPUs (2 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_4_LSSD + bool "c4a-highmem-4-lssd" + depends on TARGET_ARCH_ARM64 + help + 4 vCPUs (2 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_8 + bool "c4a-highmem-8" + depends on TARGET_ARCH_ARM64 + help + 8 vCPUs (4 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_8_LSSD + bool "c4a-highmem-8-lssd" + depends on TARGET_ARCH_ARM64 + help + 8 vCPUs (4 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_16 + bool "c4a-highmem-16" + depends on TARGET_ARCH_ARM64 + help + 16 vCPUs (8 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_16_LSSD + bool "c4a-highmem-16-lssd" + depends on TARGET_ARCH_ARM64 + help + 16 vCPUs (8 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_32 + bool "c4a-highmem-32" + depends on TARGET_ARCH_ARM64 + help + 32 vCPUs (16 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_32_LSSD + bool "c4a-highmem-32-lssd" + depends on TARGET_ARCH_ARM64 + help + 32 vCPUs (16 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_48 + bool "c4a-highmem-48" + depends on TARGET_ARCH_ARM64 + help + 48 vCPUs (24 cores) and 384GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_48_LSSD + bool "c4a-highmem-48-lssd" + depends on TARGET_ARCH_ARM64 + help + 48 vCPUs (24 cores) and 384GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_64 + bool "c4a-highmem-64" + depends on TARGET_ARCH_ARM64 + help + 64 vCPUs (32 cores) and 512GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_64_LSSD + bool "c4a-highmem-64-lssd" + depends on TARGET_ARCH_ARM64 + help + 64 vCPUs (32 cores) and 512GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_72 + bool "c4a-highmem-72" + depends on TARGET_ARCH_ARM64 + help + 72 vCPUs (36 cores) and 576GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_72_LSSD + bool "c4a-highmem-72-lssd" + depends on TARGET_ARCH_ARM64 + help + 72 vCPUs (36 cores) and 576GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4a-highmem-1" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_1 + default "c4a-highmem-2" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_2 + default "c4a-highmem-4" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_4 + default "c4a-highmem-4-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_4_LSSD + default "c4a-highmem-8" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_8 + default "c4a-highmem-8-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_8_LSSD + default "c4a-highmem-16" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_16 + default "c4a-highmem-16-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_16_LSSD + default "c4a-highmem-32" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_32 + default "c4a-highmem-32-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_32_LSSD + default "c4a-highmem-48" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_48 + default "c4a-highmem-48-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_48_LSSD + default "c4a-highmem-64" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_64 + default "c4a-highmem-64-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_64_LSSD + default "c4a-highmem-72" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_72 + default "c4a-highmem-72-lssd" if TERRAFORM_GCE_MACHINE_C4A_HIGHMEM_72_LSSD + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4A_HIGHMEM + +if TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 + help + Fourth generation compute-optimized balanced with Arm-based Axion processors. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 + bool "c4a-standard-1" + depends on TARGET_ARCH_ARM64 + help + 1 vCPU and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 + bool "c4a-standard-2" + depends on TARGET_ARCH_ARM64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 + bool "c4a-standard-4" + depends on TARGET_ARCH_ARM64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_4_LSSD + bool "c4a-standard-4-lssd" + depends on TARGET_ARCH_ARM64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 + bool "c4a-standard-8" + depends on TARGET_ARCH_ARM64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_8_LSSD + bool "c4a-standard-8-lssd" + depends on TARGET_ARCH_ARM64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 + bool "c4a-standard-16" + depends on TARGET_ARCH_ARM64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_16_LSSD + bool "c4a-standard-16-lssd" + depends on TARGET_ARCH_ARM64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 + bool "c4a-standard-32" + depends on TARGET_ARCH_ARM64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_32_LSSD + bool "c4a-standard-32-lssd" + depends on TARGET_ARCH_ARM64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_48 + bool "c4a-standard-48" + depends on TARGET_ARCH_ARM64 + help + 48 vCPUs (24 cores) and 192GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_48_LSSD + bool "c4a-standard-48-lssd" + depends on TARGET_ARCH_ARM64 + help + 48 vCPUs (24 cores) and 192GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_64 + bool "c4a-standard-64" + depends on TARGET_ARCH_ARM64 + help + 64 vCPUs (32 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_64_LSSD + bool "c4a-standard-64-lssd" + depends on TARGET_ARCH_ARM64 + help + 64 vCPUs (32 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_72 + bool "c4a-standard-72" + depends on TARGET_ARCH_ARM64 + help + 72 vCPUs (36 cores) and 288GB of memory. + +config TERRAFORM_GCE_MACHINE_C4A_STANDARD_72_LSSD + bool "c4a-standard-72-lssd" + depends on TARGET_ARCH_ARM64 + help + 72 vCPUs (36 cores) and 288GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "c4a-standard-1" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_1 + default "c4a-standard-2" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_2 + default "c4a-standard-4" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_4 + default "c4a-standard-4-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_4_LSSD + default "c4a-standard-8" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_8 + default "c4a-standard-8-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_8_LSSD + default "c4a-standard-16" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_16 + default "c4a-standard-16-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_16_LSSD + default "c4a-standard-32" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_32 + default "c4a-standard-32-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_32_LSSD + default "c4a-standard-48" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_48 + default "c4a-standard-48-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_48_LSSD + default "c4a-standard-64" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_64 + default "c4a-standard-64-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_64_LSSD + default "c4a-standard-72" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_72 + default "c4a-standard-72-lssd" if TERRAFORM_GCE_MACHINE_C4A_STANDARD_72_LSSD + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_C4A_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 + help + Cost-optimized compute-intensive on Intel or AMD processors. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 + bool "e2-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 + bool "e2-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 + bool "e2-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 + bool "e2-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 + bool "e2-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 32GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-highcpu-2" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_2 + default "e2-highcpu-4" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_4 + default "e2-highcpu-8" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_8 + default "e2-highcpu-16" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_16 + default "e2-highcpu-32" if TERRAFORM_GCE_MACHINE_E2_HIGHCPU_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_HIGHMEM_2 + help + Cost-optimized memory-intensive on Intel or AMD processors. + +config TERRAFORM_GCE_MACHINE_E2_HIGHMEM_2 + bool "e2-highmem-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHMEM_4 + bool "e2-highmem-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHMEM_8 + bool "e2-highmem-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_HIGHMEM_16 + bool "e2-highmem-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 128GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-highmem-2" if TERRAFORM_GCE_MACHINE_E2_HIGHMEM_2 + default "e2-highmem-4" if TERRAFORM_GCE_MACHINE_E2_HIGHMEM_4 + default "e2-highmem-8" if TERRAFORM_GCE_MACHINE_E2_HIGHMEM_8 + default "e2-highmem-16" if TERRAFORM_GCE_MACHINE_E2_HIGHMEM_16 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_HIGHMEM + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_MEDIUM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_MEDIUM + help + Cost-optimized shared-core machine with 2 vCPUs and 4 GB memory. + +config TERRAFORM_GCE_MACHINE_E2_MEDIUM + bool "e2-medium" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 4GB of memory. + Shared-core machine type. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-medium" if TERRAFORM_GCE_MACHINE_E2_MEDIUM + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_MEDIUM + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_MICRO + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_MICRO + help + Cost-optimized shared-core machine with 2 vCPUs and 1 GB memory. + +config TERRAFORM_GCE_MACHINE_E2_MICRO + bool "e2-micro" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 1GB of memory. + Shared-core machine type. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-micro" if TERRAFORM_GCE_MACHINE_E2_MICRO + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_MICRO + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_SMALL + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_SMALL + help + Cost-optimized shared-core machine with 2 vCPUs and 2 GB memory. + +config TERRAFORM_GCE_MACHINE_E2_SMALL + bool "e2-small" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + Shared-core machine type. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-small" if TERRAFORM_GCE_MACHINE_E2_SMALL + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_SMALL + +if TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_E2_STANDARD_2 + help + Cost-optimized balanced on Intel or AMD processors. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_2 + bool "e2-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_4 + bool "e2-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_8 + bool "e2-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_16 + bool "e2-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_E2_STANDARD_32 + bool "e2-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "e2-standard-2" if TERRAFORM_GCE_MACHINE_E2_STANDARD_2 + default "e2-standard-4" if TERRAFORM_GCE_MACHINE_E2_STANDARD_4 + default "e2-standard-8" if TERRAFORM_GCE_MACHINE_E2_STANDARD_8 + default "e2-standard-16" if TERRAFORM_GCE_MACHINE_E2_STANDARD_16 + default "e2-standard-32" if TERRAFORM_GCE_MACHINE_E2_STANDARD_32 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_E2_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_F1_MICRO + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_F1_MICRO + help + Legacy shared-core machine type. Consider using e2-micro instead. + +config TERRAFORM_GCE_MACHINE_F1_MICRO + bool "f1-micro" + depends on TARGET_ARCH_X86_64 + help + 1 vCPU and 0.6GB of memory. + Shared-core machine type. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "f1-micro" if TERRAFORM_GCE_MACHINE_F1_MICRO + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_F1_MICRO + +if TERRAFORM_GCE_MACHINE_FAMILY_G1_SMALL + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_G1_SMALL + help + Legacy shared-core machine type. Consider using e2-small instead. + +config TERRAFORM_GCE_MACHINE_G1_SMALL + bool "g1-small" + depends on TARGET_ARCH_X86_64 + help + 1 vCPU and 1.7GB of memory. + Shared-core machine type. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "g1-small" if TERRAFORM_GCE_MACHINE_G1_SMALL + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_G1_SMALL + +if TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 + help + First generation compute-intensive on Intel Haswell/Broadwell/Skylake. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 + bool "n1-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 1.8GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 + bool "n1-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 3.6GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 + bool "n1-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 7.2GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 + bool "n1-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 14.4GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 + bool "n1-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 28.8GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_64 + bool "n1-highcpu-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 57.6GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHCPU_96 + bool "n1-highcpu-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 86.4GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n1-highcpu-2" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_2 + default "n1-highcpu-4" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_4 + default "n1-highcpu-8" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_8 + default "n1-highcpu-16" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_16 + default "n1-highcpu-32" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_32 + default "n1-highcpu-64" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_64 + default "n1-highcpu-96" if TERRAFORM_GCE_MACHINE_N1_HIGHCPU_96 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N1_HIGHMEM_2 + help + First generation memory-intensive on Intel Haswell/Broadwell/Skylake. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_2 + bool "n1-highmem-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 13GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_4 + bool "n1-highmem-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 26GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_8 + bool "n1-highmem-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 52GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_16 + bool "n1-highmem-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 104GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_32 + bool "n1-highmem-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 208GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_64 + bool "n1-highmem-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 416GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_HIGHMEM_96 + bool "n1-highmem-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 624GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n1-highmem-2" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_2 + default "n1-highmem-4" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_4 + default "n1-highmem-8" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_8 + default "n1-highmem-16" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_16 + default "n1-highmem-32" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_32 + default "n1-highmem-64" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_64 + default "n1-highmem-96" if TERRAFORM_GCE_MACHINE_N1_HIGHMEM_96 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_HIGHMEM + +if TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N1_STANDARD_1 + help + First generation balanced on Intel Haswell/Broadwell/Skylake. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_1 + bool "n1-standard-1" + depends on TARGET_ARCH_X86_64 + help + 1 vCPU and 3.8GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_2 + bool "n1-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 7.5GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_4 + bool "n1-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 15GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_8 + bool "n1-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 30GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_16 + bool "n1-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 60GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_32 + bool "n1-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 120GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_64 + bool "n1-standard-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 240GB of memory. + +config TERRAFORM_GCE_MACHINE_N1_STANDARD_96 + bool "n1-standard-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 360GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n1-standard-1" if TERRAFORM_GCE_MACHINE_N1_STANDARD_1 + default "n1-standard-2" if TERRAFORM_GCE_MACHINE_N1_STANDARD_2 + default "n1-standard-4" if TERRAFORM_GCE_MACHINE_N1_STANDARD_4 + default "n1-standard-8" if TERRAFORM_GCE_MACHINE_N1_STANDARD_8 + default "n1-standard-16" if TERRAFORM_GCE_MACHINE_N1_STANDARD_16 + default "n1-standard-32" if TERRAFORM_GCE_MACHINE_N1_STANDARD_32 + default "n1-standard-64" if TERRAFORM_GCE_MACHINE_N1_STANDARD_64 + default "n1-standard-96" if TERRAFORM_GCE_MACHINE_N1_STANDARD_96 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N1_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 + help + Second generation compute-intensive on Intel Cascade Lake or Ice Lake. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 + bool "n2-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 + bool "n2-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 + bool "n2-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 + bool "n2-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 + bool "n2-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_48 + bool "n2-highcpu-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 48GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_64 + bool "n2-highcpu-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_80 + bool "n2-highcpu-80" + depends on TARGET_ARCH_X86_64 + help + 80 vCPUs (40 cores) and 80GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHCPU_96 + bool "n2-highcpu-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 96GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2-highcpu-2" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_2 + default "n2-highcpu-4" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_4 + default "n2-highcpu-8" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_8 + default "n2-highcpu-16" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_16 + default "n2-highcpu-32" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_32 + default "n2-highcpu-48" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_48 + default "n2-highcpu-64" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_64 + default "n2-highcpu-80" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_80 + default "n2-highcpu-96" if TERRAFORM_GCE_MACHINE_N2_HIGHCPU_96 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2_HIGHMEM_2 + help + Second generation memory-intensive on Intel Cascade Lake or Ice Lake. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_2 + bool "n2-highmem-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_4 + bool "n2-highmem-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_8 + bool "n2-highmem-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_16 + bool "n2-highmem-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_32 + bool "n2-highmem-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_48 + bool "n2-highmem-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 384GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_64 + bool "n2-highmem-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 512GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_80 + bool "n2-highmem-80" + depends on TARGET_ARCH_X86_64 + help + 80 vCPUs (40 cores) and 640GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_96 + bool "n2-highmem-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 768GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_HIGHMEM_128 + bool "n2-highmem-128" + depends on TARGET_ARCH_X86_64 + help + 128 vCPUs (64 cores) and 864GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2-highmem-2" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_2 + default "n2-highmem-4" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_4 + default "n2-highmem-8" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_8 + default "n2-highmem-16" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_16 + default "n2-highmem-32" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_32 + default "n2-highmem-48" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_48 + default "n2-highmem-64" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_64 + default "n2-highmem-80" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_80 + default "n2-highmem-96" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_96 + default "n2-highmem-128" if TERRAFORM_GCE_MACHINE_N2_HIGHMEM_128 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_HIGHMEM + +if TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2_STANDARD_8 + help + Second generation balanced on Intel Cascade Lake or Ice Lake. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_2 + bool "n2-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_4 + bool "n2-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_8 + bool "n2-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_16 + bool "n2-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_32 + bool "n2-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_48 + bool "n2-standard-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 192GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_64 + bool "n2-standard-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_80 + bool "n2-standard-80" + depends on TARGET_ARCH_X86_64 + help + 80 vCPUs (40 cores) and 320GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_96 + bool "n2-standard-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 384GB of memory. + +config TERRAFORM_GCE_MACHINE_N2_STANDARD_128 + bool "n2-standard-128" + depends on TARGET_ARCH_X86_64 + help + 128 vCPUs (64 cores) and 512GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2-standard-2" if TERRAFORM_GCE_MACHINE_N2_STANDARD_2 + default "n2-standard-4" if TERRAFORM_GCE_MACHINE_N2_STANDARD_4 + default "n2-standard-8" if TERRAFORM_GCE_MACHINE_N2_STANDARD_8 + default "n2-standard-16" if TERRAFORM_GCE_MACHINE_N2_STANDARD_16 + default "n2-standard-32" if TERRAFORM_GCE_MACHINE_N2_STANDARD_32 + default "n2-standard-48" if TERRAFORM_GCE_MACHINE_N2_STANDARD_48 + default "n2-standard-64" if TERRAFORM_GCE_MACHINE_N2_STANDARD_64 + default "n2-standard-80" if TERRAFORM_GCE_MACHINE_N2_STANDARD_80 + default "n2-standard-96" if TERRAFORM_GCE_MACHINE_N2_STANDARD_96 + default "n2-standard-128" if TERRAFORM_GCE_MACHINE_N2_STANDARD_128 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 + help + Second generation compute-intensive on AMD EPYC Rome or Milan. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 + bool "n2d-highcpu-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 2GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 + bool "n2d-highcpu-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 + bool "n2d-highcpu-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 + bool "n2d-highcpu-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 + bool "n2d-highcpu-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_48 + bool "n2d-highcpu-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 48GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_64 + bool "n2d-highcpu-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_80 + bool "n2d-highcpu-80" + depends on TARGET_ARCH_X86_64 + help + 80 vCPUs (40 cores) and 80GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_96 + bool "n2d-highcpu-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 96GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_128 + bool "n2d-highcpu-128" + depends on TARGET_ARCH_X86_64 + help + 128 vCPUs (64 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_224 + bool "n2d-highcpu-224" + depends on TARGET_ARCH_X86_64 + help + 224 vCPUs (112 cores) and 224GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2d-highcpu-2" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_2 + default "n2d-highcpu-4" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_4 + default "n2d-highcpu-8" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_8 + default "n2d-highcpu-16" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_16 + default "n2d-highcpu-32" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_32 + default "n2d-highcpu-48" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_48 + default "n2d-highcpu-64" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_64 + default "n2d-highcpu-80" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_80 + default "n2d-highcpu-96" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_96 + default "n2d-highcpu-128" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_128 + default "n2d-highcpu-224" if TERRAFORM_GCE_MACHINE_N2D_HIGHCPU_224 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHCPU + +if TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_2 + help + Second generation memory-intensive on AMD EPYC Rome or Milan. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_2 + bool "n2d-highmem-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_4 + bool "n2d-highmem-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_8 + bool "n2d-highmem-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_16 + bool "n2d-highmem-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_32 + bool "n2d-highmem-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_48 + bool "n2d-highmem-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 384GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_64 + bool "n2d-highmem-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 512GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_80 + bool "n2d-highmem-80" + depends on TARGET_ARCH_X86_64 + help + 80 vCPUs (40 cores) and 640GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_96 + bool "n2d-highmem-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 768GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2d-highmem-2" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_2 + default "n2d-highmem-4" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_4 + default "n2d-highmem-8" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_8 + default "n2d-highmem-16" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_16 + default "n2d-highmem-32" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_32 + default "n2d-highmem-48" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_48 + default "n2d-highmem-64" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_64 + default "n2d-highmem-80" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_80 + default "n2d-highmem-96" if TERRAFORM_GCE_MACHINE_N2D_HIGHMEM_96 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_HIGHMEM + +if TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 + help + Second generation balanced on AMD EPYC Rome or Milan. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 + bool "n2d-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 + bool "n2d-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 + bool "n2d-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 + bool "n2d-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 + bool "n2d-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_48 + bool "n2d-standard-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 192GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_64 + bool "n2d-standard-64" + depends on TARGET_ARCH_X86_64 + help + 64 vCPUs (32 cores) and 256GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_80 + bool "n2d-standard-80" + depends on TARGET_ARCH_X86_64 + help + 80 vCPUs (40 cores) and 320GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_96 + bool "n2d-standard-96" + depends on TARGET_ARCH_X86_64 + help + 96 vCPUs (48 cores) and 384GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_128 + bool "n2d-standard-128" + depends on TARGET_ARCH_X86_64 + help + 128 vCPUs (64 cores) and 512GB of memory. + +config TERRAFORM_GCE_MACHINE_N2D_STANDARD_224 + bool "n2d-standard-224" + depends on TARGET_ARCH_X86_64 + help + 224 vCPUs (112 cores) and 896GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "n2d-standard-2" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_2 + default "n2d-standard-4" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_4 + default "n2d-standard-8" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_8 + default "n2d-standard-16" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_16 + default "n2d-standard-32" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_32 + default "n2d-standard-48" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_48 + default "n2d-standard-64" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_64 + default "n2d-standard-80" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_80 + default "n2d-standard-96" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_96 + default "n2d-standard-128" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_128 + default "n2d-standard-224" if TERRAFORM_GCE_MACHINE_N2D_STANDARD_224 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_N2D_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_T2D_STANDARD + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_T2D_STANDARD_1 + help + Scale-out optimized on AMD EPYC Milan. Good for web and containerized workloads. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_1 + bool "t2d-standard-1" + depends on TARGET_ARCH_X86_64 + help + 1 vCPU and 4GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_2 + bool "t2d-standard-2" + depends on TARGET_ARCH_X86_64 + help + 2 vCPUs (1 core) and 8GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_4 + bool "t2d-standard-4" + depends on TARGET_ARCH_X86_64 + help + 4 vCPUs (2 cores) and 16GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_8 + bool "t2d-standard-8" + depends on TARGET_ARCH_X86_64 + help + 8 vCPUs (4 cores) and 32GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_16 + bool "t2d-standard-16" + depends on TARGET_ARCH_X86_64 + help + 16 vCPUs (8 cores) and 64GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_32 + bool "t2d-standard-32" + depends on TARGET_ARCH_X86_64 + help + 32 vCPUs (16 cores) and 128GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_48 + bool "t2d-standard-48" + depends on TARGET_ARCH_X86_64 + help + 48 vCPUs (24 cores) and 192GB of memory. + +config TERRAFORM_GCE_MACHINE_T2D_STANDARD_60 + bool "t2d-standard-60" + depends on TARGET_ARCH_X86_64 + help + 60 vCPUs (30 cores) and 240GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "t2d-standard-1" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_1 + default "t2d-standard-2" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_2 + default "t2d-standard-4" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_4 + default "t2d-standard-8" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_8 + default "t2d-standard-16" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_16 + default "t2d-standard-32" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_32 + default "t2d-standard-48" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_48 + default "t2d-standard-60" if TERRAFORM_GCE_MACHINE_T2D_STANDARD_60 + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_T2D_STANDARD + +if TERRAFORM_GCE_MACHINE_FAMILY_Z3_HIGHMEM + +choice + prompt "GCE Machine type" + default TERRAFORM_GCE_MACHINE_Z3_HIGHMEM_192_HIGHLSSD_METAL + help + Storage-optimized with large local SSD capacity for databases and analytics. + +config TERRAFORM_GCE_MACHINE_Z3_HIGHMEM_192_HIGHLSSD_METAL + bool "z3-highmem-192-highlssd-metal" + depends on TARGET_ARCH_X86_64 + help + 192 vCPUs (96 cores) and 1536GB of memory. + +endchoice + +config TERRAFORM_GCE_MACHINE_TYPE + string + output yaml + default "z3-highmem-192-highlssd-metal" if TERRAFORM_GCE_MACHINE_Z3_HIGHMEM_192_HIGHLSSD_METAL + +config TERRAFORM_GCE_IMAGE_TYPE + string + output yaml + default "pd-balanced" + +endif # TERRAFORM_GCE_MACHINE_FAMILY_Z3_HIGHMEM +