|
20 | 20 | Get available zones in region |
21 | 21 | *****************************************/ |
22 | 22 | data "google_compute_zones" "available" { |
23 | | - provider = "{% if private_cluster %}google-beta{%else %}google{% endif %}" |
| 23 | + provider = "{% if private_cluster or beta_cluster %}google-beta{% else %}google{% endif %}" |
24 | 24 | project = "${var.project_id}" |
25 | 25 | region = "${var.region}" |
26 | 26 | } |
@@ -129,6 +129,20 @@ locals { |
129 | 129 | zonal = "${element(concat(google_container_cluster.zonal_primary.*.addons_config.0.kubernetes_dashboard.0.disabled, list("")), 0)}" |
130 | 130 | } |
131 | 131 |
|
| 132 | + {% if beta_cluster %} |
| 133 | + # BETA features |
| 134 | + cluster_type_output_istio_enabled = { |
| 135 | + regional = "${element(concat(google_container_cluster.primary.*.addons_config.0.istio_config.0.disabled, list("")), 0)}" |
| 136 | + zonal = "${element(concat(google_container_cluster.zonal_primary.*.addons_config.0.istio_config.0.disabled, list("")), 0)}" |
| 137 | + } |
| 138 | + |
| 139 | + cluster_type_output_cloudrun_enabled = { |
| 140 | + regional = "${element(concat(google_container_cluster.primary.*.addons_config.0.cloudrun_config.0.disabled, list("")), 0)}" |
| 141 | + zonal = "${element(concat(google_container_cluster.zonal_primary.*.addons_config.0.cloudrun_config.0.disabled, list("")), 0)}" |
| 142 | + } |
| 143 | + # /BETA features |
| 144 | + {% endif %} |
| 145 | + |
132 | 146 | cluster_type_output_node_pools_names = { |
133 | 147 | regional = "${concat(google_container_node_pool.pools.*.name, list(""))}" |
134 | 148 | zonal = "${concat(google_container_node_pool.zonal_pools.*.name, list(""))}" |
@@ -168,6 +182,12 @@ locals { |
168 | 182 | cluster_http_load_balancing_enabled = "${local.cluster_type_output_http_load_balancing_enabled[local.cluster_type] ? false : true}" |
169 | 183 | cluster_horizontal_pod_autoscaling_enabled = "${local.cluster_type_output_horizontal_pod_autoscaling_enabled[local.cluster_type] ? false : true}" |
170 | 184 | cluster_kubernetes_dashboard_enabled = "${local.cluster_type_output_kubernetes_dashboard_enabled[local.cluster_type] ? false : true}" |
| 185 | +{% if beta_cluster %} |
| 186 | + # BETA features |
| 187 | + cluster_istio_enabled = "${local.cluster_type_output_istio_enabled[local.cluster_type] ? false : true}" |
| 188 | + cluster_cloudrun_enabled = "${local.cluster_type_output_cloudrun_enabled[local.cluster_type] ? false : true}" |
| 189 | + # /BETA features |
| 190 | +{% endif %} |
171 | 191 | {% if private_cluster %} |
172 | 192 | cluster_pod_security_policy_enabled = "${local.cluster_type_output_pod_security_policy_enabled[local.cluster_type] ? true : false}" |
173 | 193 | {% endif %} |
|
0 commit comments