Skip to content

Commit 2c38f12

Browse files
committed
Regenerate modules
1 parent a9613ef commit 2c38f12

20 files changed

+108
-80
lines changed

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -234,6 +234,11 @@ To more cleanly handle cases where desired functionality would require complex d
234234

235235
The root module is generated by running `make generate`. Changes to this repository should be made in the [`autogen`](/autogen) directory where appropriate.
236236

237+
Note: The correct sequence to update the repo using autogen
238+
functionality is the run `make generate && make generate_docs`. This
239+
will create the various Terraform files, and then generate the
240+
Terraform documentation using `terraform-docs`.
241+
237242
## Testing
238243

239244
### Requirements

cluster_regional.tf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ resource "google_container_cluster" "primary" {
2626
description = "${var.description}"
2727
project = "${var.project_id}"
2828

29-
region = "${var.region}"
30-
node_locations = ["${coalescelist(compact(var.zones), sort(random_shuffle.available_zones.result))}"]
29+
region = "${var.region}"
30+
node_locations = ["${coalescelist(compact(var.zones), sort(random_shuffle.available_zones.result))}"]
3131
cluster_ipv4_cidr = "${var.cluster_ipv4_cidr}"
32-
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
32+
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
3333

3434
network_policy {
3535
enabled = "${var.network_policy}"
@@ -100,6 +100,7 @@ resource "google_container_cluster" "primary" {
100100
service_account = "${lookup(var.node_pools[0], "service_account", local.service_account)}"
101101
}
102102
}
103+
103104
remove_default_node_pool = "${var.remove_default_node_pool}"
104105
}
105106

cluster_zonal.tf

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ resource "google_container_cluster" "zonal_primary" {
2626
description = "${var.description}"
2727
project = "${var.project_id}"
2828

29-
zone = "${var.zones[0]}"
30-
node_locations = ["${slice(var.zones,1,length(var.zones))}"]
29+
zone = "${var.zones[0]}"
30+
node_locations = ["${slice(var.zones,1,length(var.zones))}"]
3131
cluster_ipv4_cidr = "${var.cluster_ipv4_cidr}"
32-
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
32+
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
3333

3434
network_policy {
3535
enabled = "${var.network_policy}"
@@ -100,6 +100,7 @@ resource "google_container_cluster" "zonal_primary" {
100100
service_account = "${lookup(var.node_pools[0], "service_account", local.service_account)}"
101101
}
102102
}
103+
103104
remove_default_node_pool = "${var.remove_default_node_pool}"
104105
}
105106

main.tf

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -128,19 +128,18 @@ locals {
128128
cluster_master_auth_map = "${local.cluster_master_auth_list_layer2[0]}"
129129

130130
# cluster locals
131-
cluster_name = "${local.cluster_type_output_name[local.cluster_type]}"
132-
cluster_location = "${local.cluster_type_output_location[local.cluster_type]}"
133-
cluster_region = "${local.cluster_type_output_region[local.cluster_type]}"
134-
cluster_zones = "${sort(local.cluster_type_output_zones[local.cluster_type])}"
135-
cluster_endpoint = "${local.cluster_type_output_endpoint[local.cluster_type]}"
136-
cluster_ca_certificate = "${lookup(local.cluster_master_auth_map, "cluster_ca_certificate")}"
137-
cluster_master_version = "${local.cluster_type_output_master_version[local.cluster_type]}"
138-
cluster_min_master_version = "${local.cluster_type_output_min_master_version[local.cluster_type]}"
139-
cluster_logging_service = "${local.cluster_type_output_logging_service[local.cluster_type]}"
140-
cluster_monitoring_service = "${local.cluster_type_output_monitoring_service[local.cluster_type]}"
141-
cluster_node_pools_names = "${local.cluster_type_output_node_pools_names[local.cluster_type]}"
142-
cluster_node_pools_versions = "${local.cluster_type_output_node_pools_versions[local.cluster_type]}"
143-
131+
cluster_name = "${local.cluster_type_output_name[local.cluster_type]}"
132+
cluster_location = "${local.cluster_type_output_location[local.cluster_type]}"
133+
cluster_region = "${local.cluster_type_output_region[local.cluster_type]}"
134+
cluster_zones = "${sort(local.cluster_type_output_zones[local.cluster_type])}"
135+
cluster_endpoint = "${local.cluster_type_output_endpoint[local.cluster_type]}"
136+
cluster_ca_certificate = "${lookup(local.cluster_master_auth_map, "cluster_ca_certificate")}"
137+
cluster_master_version = "${local.cluster_type_output_master_version[local.cluster_type]}"
138+
cluster_min_master_version = "${local.cluster_type_output_min_master_version[local.cluster_type]}"
139+
cluster_logging_service = "${local.cluster_type_output_logging_service[local.cluster_type]}"
140+
cluster_monitoring_service = "${local.cluster_type_output_monitoring_service[local.cluster_type]}"
141+
cluster_node_pools_names = "${local.cluster_type_output_node_pools_names[local.cluster_type]}"
142+
cluster_node_pools_versions = "${local.cluster_type_output_node_pools_versions[local.cluster_type]}"
144143
cluster_network_policy_enabled = "${local.cluster_type_output_network_policy_enabled[local.cluster_type] ? false : true}"
145144
cluster_http_load_balancing_enabled = "${local.cluster_type_output_http_load_balancing_enabled[local.cluster_type] ? false : true}"
146145
cluster_horizontal_pod_autoscaling_enabled = "${local.cluster_type_output_horizontal_pod_autoscaling_enabled[local.cluster_type] ? false : true}"

modules/beta-private-cluster/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -253,6 +253,11 @@ To more cleanly handle cases where desired functionality would require complex d
253253

254254
The root module is generated by running `make generate`. Changes to this repository should be made in the [`autogen`](/autogen) directory where appropriate.
255255

256+
Note: The correct sequence to update the repo using autogen
257+
functionality is the run `make generate && make generate_docs`. This
258+
will create the various Terraform files, and then generate the
259+
Terraform documentation using `terraform-docs`.
260+
256261
## Testing
257262

258263
### Requirements

modules/beta-private-cluster/cluster_regional.tf

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ resource "google_container_cluster" "primary" {
2626
description = "${var.description}"
2727
project = "${var.project_id}"
2828

29-
region = "${var.region}"
30-
node_locations = ["${coalescelist(compact(var.zones), sort(random_shuffle.available_zones.result))}"]
29+
region = "${var.region}"
30+
node_locations = ["${coalescelist(compact(var.zones), sort(random_shuffle.available_zones.result))}"]
3131
cluster_ipv4_cidr = "${var.cluster_ipv4_cidr}"
32-
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
32+
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
3333

3434
network_policy {
3535
enabled = "${var.network_policy}"
@@ -71,6 +71,7 @@ resource "google_container_cluster" "primary" {
7171
network_policy_config {
7272
disabled = "${var.network_policy ? 0 : 1}"
7373
}
74+
7475
istio_config {
7576
disabled = "${var.istio ? 0 : 1}"
7677
}
@@ -109,11 +110,13 @@ resource "google_container_cluster" "primary" {
109110
service_account = "${lookup(var.node_pools[0], "service_account", local.service_account)}"
110111
}
111112
}
113+
112114
private_cluster_config {
113115
enable_private_endpoint = "${var.enable_private_endpoint}"
114116
enable_private_nodes = "${var.enable_private_nodes}"
115117
master_ipv4_cidr_block = "${var.master_ipv4_cidr_block}"
116118
}
119+
117120
remove_default_node_pool = "${var.remove_default_node_pool}"
118121
database_encryption = ["${var.database_encryption}"]
119122
}

modules/beta-private-cluster/cluster_zonal.tf

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ resource "google_container_cluster" "zonal_primary" {
2626
description = "${var.description}"
2727
project = "${var.project_id}"
2828

29-
zone = "${var.zones[0]}"
30-
node_locations = ["${slice(var.zones,1,length(var.zones))}"]
29+
zone = "${var.zones[0]}"
30+
node_locations = ["${slice(var.zones,1,length(var.zones))}"]
3131
cluster_ipv4_cidr = "${var.cluster_ipv4_cidr}"
32-
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
32+
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
3333

3434
network_policy {
3535
enabled = "${var.network_policy}"
@@ -71,6 +71,7 @@ resource "google_container_cluster" "zonal_primary" {
7171
network_policy_config {
7272
disabled = "${var.network_policy ? 0 : 1}"
7373
}
74+
7475
istio_config {
7576
disabled = "${var.istio ? 0 : 1}"
7677
}
@@ -109,11 +110,13 @@ resource "google_container_cluster" "zonal_primary" {
109110
service_account = "${lookup(var.node_pools[0], "service_account", local.service_account)}"
110111
}
111112
}
113+
112114
private_cluster_config {
113115
enable_private_endpoint = "${var.enable_private_endpoint}"
114116
enable_private_nodes = "${var.enable_private_nodes}"
115117
master_ipv4_cidr_block = "${var.master_ipv4_cidr_block}"
116118
}
119+
117120
remove_default_node_pool = "${var.remove_default_node_pool}"
118121
database_encryption = ["${var.database_encryption}"]
119122
}

modules/beta-private-cluster/main.tf

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -151,18 +151,18 @@ locals {
151151
cluster_master_auth_list_layer2 = "${local.cluster_master_auth_list_layer1[0]}"
152152
cluster_master_auth_map = "${local.cluster_master_auth_list_layer2[0]}"
153153
# cluster locals
154-
cluster_name = "${local.cluster_type_output_name[local.cluster_type]}"
155-
cluster_location = "${local.cluster_type_output_location[local.cluster_type]}"
156-
cluster_region = "${local.cluster_type_output_region[local.cluster_type]}"
157-
cluster_zones = "${sort(local.cluster_type_output_zones[local.cluster_type])}"
158-
cluster_endpoint = "${local.cluster_type_output_endpoint[local.cluster_type]}"
159-
cluster_ca_certificate = "${lookup(local.cluster_master_auth_map, "cluster_ca_certificate")}"
160-
cluster_master_version = "${local.cluster_type_output_master_version[local.cluster_type]}"
161-
cluster_min_master_version = "${local.cluster_type_output_min_master_version[local.cluster_type]}"
162-
cluster_logging_service = "${local.cluster_type_output_logging_service[local.cluster_type]}"
163-
cluster_monitoring_service = "${local.cluster_type_output_monitoring_service[local.cluster_type]}"
164-
cluster_node_pools_names = "${local.cluster_type_output_node_pools_names[local.cluster_type]}"
165-
cluster_node_pools_versions = "${local.cluster_type_output_node_pools_versions[local.cluster_type]}"
154+
cluster_name = "${local.cluster_type_output_name[local.cluster_type]}"
155+
cluster_location = "${local.cluster_type_output_location[local.cluster_type]}"
156+
cluster_region = "${local.cluster_type_output_region[local.cluster_type]}"
157+
cluster_zones = "${sort(local.cluster_type_output_zones[local.cluster_type])}"
158+
cluster_endpoint = "${local.cluster_type_output_endpoint[local.cluster_type]}"
159+
cluster_ca_certificate = "${lookup(local.cluster_master_auth_map, "cluster_ca_certificate")}"
160+
cluster_master_version = "${local.cluster_type_output_master_version[local.cluster_type]}"
161+
cluster_min_master_version = "${local.cluster_type_output_min_master_version[local.cluster_type]}"
162+
cluster_logging_service = "${local.cluster_type_output_logging_service[local.cluster_type]}"
163+
cluster_monitoring_service = "${local.cluster_type_output_monitoring_service[local.cluster_type]}"
164+
cluster_node_pools_names = "${local.cluster_type_output_node_pools_names[local.cluster_type]}"
165+
cluster_node_pools_versions = "${local.cluster_type_output_node_pools_versions[local.cluster_type]}"
166166
cluster_network_policy_enabled = "${local.cluster_type_output_network_policy_enabled[local.cluster_type] ? false : true}"
167167
cluster_http_load_balancing_enabled = "${local.cluster_type_output_http_load_balancing_enabled[local.cluster_type] ? false : true}"
168168
cluster_horizontal_pod_autoscaling_enabled = "${local.cluster_type_output_horizontal_pod_autoscaling_enabled[local.cluster_type] ? false : true}"

modules/beta-public-cluster/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -241,6 +241,11 @@ To more cleanly handle cases where desired functionality would require complex d
241241

242242
The root module is generated by running `make generate`. Changes to this repository should be made in the [`autogen`](/autogen) directory where appropriate.
243243

244+
Note: The correct sequence to update the repo using autogen
245+
functionality is the run `make generate && make generate_docs`. This
246+
will create the various Terraform files, and then generate the
247+
Terraform documentation using `terraform-docs`.
248+
244249
## Testing
245250

246251
### Requirements

modules/beta-public-cluster/cluster_regional.tf

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ resource "google_container_cluster" "primary" {
2626
description = "${var.description}"
2727
project = "${var.project_id}"
2828

29-
region = "${var.region}"
30-
node_locations = ["${coalescelist(compact(var.zones), sort(random_shuffle.available_zones.result))}"]
29+
region = "${var.region}"
30+
node_locations = ["${coalescelist(compact(var.zones), sort(random_shuffle.available_zones.result))}"]
3131
cluster_ipv4_cidr = "${var.cluster_ipv4_cidr}"
32-
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
32+
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
3333

3434
network_policy {
3535
enabled = "${var.network_policy}"
@@ -69,6 +69,7 @@ resource "google_container_cluster" "primary" {
6969
network_policy_config {
7070
disabled = "${var.network_policy ? 0 : 1}"
7171
}
72+
7273
istio_config {
7374
disabled = "${var.istio ? 0 : 1}"
7475
}
@@ -107,6 +108,7 @@ resource "google_container_cluster" "primary" {
107108
service_account = "${lookup(var.node_pools[0], "service_account", local.service_account)}"
108109
}
109110
}
111+
110112
remove_default_node_pool = "${var.remove_default_node_pool}"
111113
database_encryption = ["${var.database_encryption}"]
112114
}

modules/beta-public-cluster/cluster_zonal.tf

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ resource "google_container_cluster" "zonal_primary" {
2626
description = "${var.description}"
2727
project = "${var.project_id}"
2828

29-
zone = "${var.zones[0]}"
30-
node_locations = ["${slice(var.zones,1,length(var.zones))}"]
29+
zone = "${var.zones[0]}"
30+
node_locations = ["${slice(var.zones,1,length(var.zones))}"]
3131
cluster_ipv4_cidr = "${var.cluster_ipv4_cidr}"
32-
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
32+
network = "${replace(data.google_compute_network.gke_network.self_link, "https://www.googleapis.com/compute/v1/", "")}"
3333

3434
network_policy {
3535
enabled = "${var.network_policy}"
@@ -69,6 +69,7 @@ resource "google_container_cluster" "zonal_primary" {
6969
network_policy_config {
7070
disabled = "${var.network_policy ? 0 : 1}"
7171
}
72+
7273
istio_config {
7374
disabled = "${var.istio ? 0 : 1}"
7475
}
@@ -107,6 +108,7 @@ resource "google_container_cluster" "zonal_primary" {
107108
service_account = "${lookup(var.node_pools[0], "service_account", local.service_account)}"
108109
}
109110
}
111+
110112
remove_default_node_pool = "${var.remove_default_node_pool}"
111113
database_encryption = ["${var.database_encryption}"]
112114
}

modules/beta-public-cluster/main.tf

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -138,18 +138,18 @@ locals {
138138
cluster_master_auth_list_layer2 = "${local.cluster_master_auth_list_layer1[0]}"
139139
cluster_master_auth_map = "${local.cluster_master_auth_list_layer2[0]}"
140140
# cluster locals
141-
cluster_name = "${local.cluster_type_output_name[local.cluster_type]}"
142-
cluster_location = "${local.cluster_type_output_location[local.cluster_type]}"
143-
cluster_region = "${local.cluster_type_output_region[local.cluster_type]}"
144-
cluster_zones = "${sort(local.cluster_type_output_zones[local.cluster_type])}"
145-
cluster_endpoint = "${local.cluster_type_output_endpoint[local.cluster_type]}"
146-
cluster_ca_certificate = "${lookup(local.cluster_master_auth_map, "cluster_ca_certificate")}"
147-
cluster_master_version = "${local.cluster_type_output_master_version[local.cluster_type]}"
148-
cluster_min_master_version = "${local.cluster_type_output_min_master_version[local.cluster_type]}"
149-
cluster_logging_service = "${local.cluster_type_output_logging_service[local.cluster_type]}"
150-
cluster_monitoring_service = "${local.cluster_type_output_monitoring_service[local.cluster_type]}"
151-
cluster_node_pools_names = "${local.cluster_type_output_node_pools_names[local.cluster_type]}"
152-
cluster_node_pools_versions = "${local.cluster_type_output_node_pools_versions[local.cluster_type]}"
141+
cluster_name = "${local.cluster_type_output_name[local.cluster_type]}"
142+
cluster_location = "${local.cluster_type_output_location[local.cluster_type]}"
143+
cluster_region = "${local.cluster_type_output_region[local.cluster_type]}"
144+
cluster_zones = "${sort(local.cluster_type_output_zones[local.cluster_type])}"
145+
cluster_endpoint = "${local.cluster_type_output_endpoint[local.cluster_type]}"
146+
cluster_ca_certificate = "${lookup(local.cluster_master_auth_map, "cluster_ca_certificate")}"
147+
cluster_master_version = "${local.cluster_type_output_master_version[local.cluster_type]}"
148+
cluster_min_master_version = "${local.cluster_type_output_min_master_version[local.cluster_type]}"
149+
cluster_logging_service = "${local.cluster_type_output_logging_service[local.cluster_type]}"
150+
cluster_monitoring_service = "${local.cluster_type_output_monitoring_service[local.cluster_type]}"
151+
cluster_node_pools_names = "${local.cluster_type_output_node_pools_names[local.cluster_type]}"
152+
cluster_node_pools_versions = "${local.cluster_type_output_node_pools_versions[local.cluster_type]}"
153153
cluster_network_policy_enabled = "${local.cluster_type_output_network_policy_enabled[local.cluster_type] ? false : true}"
154154
cluster_http_load_balancing_enabled = "${local.cluster_type_output_http_load_balancing_enabled[local.cluster_type] ? false : true}"
155155
cluster_horizontal_pod_autoscaling_enabled = "${local.cluster_type_output_horizontal_pod_autoscaling_enabled[local.cluster_type] ? false : true}"

modules/beta-public-cluster/outputs.tf

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,4 +122,3 @@ output "cloudrun_enabled" {
122122
description = "Whether CloudRun enabled"
123123
value = "${local.cluster_cloudrun_enabled}"
124124
}
125-

modules/private-cluster/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,11 @@ To more cleanly handle cases where desired functionality would require complex d
246246

247247
The root module is generated by running `make generate`. Changes to this repository should be made in the [`autogen`](/autogen) directory where appropriate.
248248

249+
Note: The correct sequence to update the repo using autogen
250+
functionality is the run `make generate && make generate_docs`. This
251+
will create the various Terraform files, and then generate the
252+
Terraform documentation using `terraform-docs`.
253+
249254
## Testing
250255

251256
### Requirements

0 commit comments

Comments
 (0)