diff --git a/google_gke/README.md b/google_gke/README.md index c17ea242..06304ac9 100644 --- a/google_gke/README.md +++ b/google_gke/README.md @@ -401,6 +401,7 @@ module "gke" { | [grant\_registry\_access](#input\_grant\_registry\_access) | Grants created cluster-specific service account storage.objectViewer and artifactregistry.reader roles. | `bool` | `true` | no | | [kubernetes\_version](#input\_kubernetes\_version) | The Kubernetes version of the masters. If set to 'latest' it will pull latest available version. Defaults to 'latest'. | `string` | `"latest"` | no | | [labels](#input\_labels) | The GCE resource labels (a map of key/value pairs) to be applied to the cluster & other cluster-related resources. Merged with default labels (see locals.tf). | `map(string)` | `{}` | no | +| [logging\_config\_components](#input\_logging\_config\_components) | n/a | `list(string)` |
[
"APISERVER",
"CONTROLLER_MANAGER",
"SCHEDULER",
"SYSTEM_COMPONENTS",
"WORKLOADS"
]
| no | | [maintenance\_exclusions](#input\_maintenance\_exclusions) | List of maintenance exclusions. A cluster can have up to three | `list(object({ name = string, start_time = string, end_time = string }))` | `[]` | no | | [maintenance\_start\_time](#input\_maintenance\_start\_time) | Time window specified for daily or recurring maintenance operations in RFC3339 format | `string` | `"21:00"` | no | | [master\_authorized\_networks](#input\_master\_authorized\_networks) | List of master authorized networks that can access the GKE Master Plane. If none are provided, it defaults to known Bastion hosts for the given realm. See locals.tf for defaults. | `list(object({ cidr_block = string, display_name = string }))` |
[
{
"cidr_block": "192.0.0.8/32",
"display_name": "tf module placeholder"
}
]
| no | diff --git a/google_gke/cluster.tf b/google_gke/cluster.tf index bcfb567c..8d8d17a7 100644 --- a/google_gke/cluster.tf +++ b/google_gke/cluster.tf @@ -107,13 +107,7 @@ resource "google_container_cluster" "primary" { # Observability logging_config { - enable_components = [ - "APISERVER", - "CONTROLLER_MANAGER", - "SCHEDULER", - "SYSTEM_COMPONENTS", - "WORKLOADS" - ] + enable_components = var.logging_config_components } monitoring_config { diff --git a/google_gke/variables.tf b/google_gke/variables.tf index ab773619..034bc7fc 100644 --- a/google_gke/variables.tf +++ b/google_gke/variables.tf @@ -448,3 +448,14 @@ variable "enable_ray_cluster_monitoring" { type = bool default = true } + +variable "logging_config_components" { + type = list(string) + default = [ + "APISERVER", + "CONTROLLER_MANAGER", + "SCHEDULER", + "SYSTEM_COMPONENTS", + "WORKLOADS" + ] +}