From 342b5ab0ea8829b6414b763f3a33873407542b76 Mon Sep 17 00:00:00 2001 From: Max Glotov Date: Tue, 19 Dec 2023 16:55:45 +0600 Subject: [PATCH 1/2] enh: delete cpu.limits from the limitrange configuration --- .../eks-kubernetes-namespace/README.md | 48 ++++++++----------- .../eks-kubernetes-namespace/variables.tf | 1 - 2 files changed, 21 insertions(+), 28 deletions(-) diff --git a/terraform/modules/eks-kubernetes-namespace/README.md b/terraform/modules/eks-kubernetes-namespace/README.md index d67b8253..979cea94 100644 --- a/terraform/modules/eks-kubernetes-namespace/README.md +++ b/terraform/modules/eks-kubernetes-namespace/README.md @@ -1,13 +1,12 @@ - ## Requirements No requirements. ## Providers -| Name | Version | -| ---------------------------------------------------------------------- | ------- | -| [kubernetes](#provider\_kubernetes) | n/a | +| Name | Version | +|------|---------| +| [kubernetes](#provider\_kubernetes) | n/a | ## Modules @@ -15,34 +14,29 @@ No modules. ## Resources -| Name | Type | -| ----------------------------------------------------------------------------------------------------------------------------------- | -------- | -| [kubernetes_limit_range.this](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/limit_range) | resource | -| [kubernetes_namespace.this](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/namespace) | resource | +| Name | Type | +|------|------| +| [kubernetes_limit_range.this](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/limit_range) | resource | +| [kubernetes_namespace.this](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/namespace) | resource | | [kubernetes_network_policy.this](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/network_policy) | resource | | [kubernetes_resource_quota.this](https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/resource_quota) | resource | ## Inputs -| Name | Description | Type | Default | Required | -| ------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------- | ---------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | :------: | -| [annotations](#input\_annotations) | An unstructured key value map stored with the namespace that may be used to store arbitrary metadata | `map(any)` | `{}` | no | -| [depends](#input\_depends) | Indicates the resource this resource depends on. | `any` | `null` | no | -| [enable](#input\_enable) | If set to true, create namespace | `bool` | `true` | no | -| [labels](#input\_labels) | Map of string keys and values that can be used to organize and categorize (scope and select) namespaces. | `map(any)` | `{}` | no | -| [limits](#input\_limits) | n/a | `any` |
[
{
"default": {
"cpu": "150m",
"memory": "128Mi"
},
"default_request": {
"cpu": "100m",
"memory": "64Mi"
},
"type": "Container"
}
]
| no | -| [name](#input\_name) | Name of the namespace, must be unique. Cannot be updated. | `string` | n/a | yes | -| [network\_policies](#input\_network\_policies) | n/a | `any` | `[]` | no | -| [resource\_quotas](#input\_resource\_quotas) | n/a | `any` | `[]` | no | +| Name | Description | Type | Default | Required | +|------|-------------|------|---------|:--------:| +| [annotations](#input\_annotations) | An unstructured key value map stored with the namespace that may be used to store arbitrary metadata | `map(any)` | `{}` | no | +| [depends](#input\_depends) | Indicates the resource this resource depends on. | `any` | `null` | no | +| [enable](#input\_enable) | If set to true, create namespace | `bool` | `true` | no | +| [labels](#input\_labels) | Map of string keys and values that can be used to organize and categorize (scope and select) namespaces. | `map(any)` | `{}` | no | +| [limits](#input\_limits) | n/a | `any` |
[
{
"default": {
"memory": "128Mi"
},
"default_request": {
"cpu": "100m",
"memory": "64Mi"
},
"type": "Container"
}
]
| no | +| [name](#input\_name) | Name of the namespace, must be unique. Cannot be updated. | `string` | n/a | yes | +| [network\_policies](#input\_network\_policies) | n/a | `any` | `[]` | no | +| [resource\_quotas](#input\_resource\_quotas) | n/a | `any` | `[]` | no | ## Outputs -| Name | Description | -| ----------------------------------------------------------------------- | -------------------------------------------------------- | -| [labels\_name](#output\_labels\_name) | The value of the name label | -| [name](#output\_name) | The name of the created namespace (from object metadata) | - - - - -# More details about using this module can be found [here](../../../docs/FAQ.md#k8s-namespace-features) +| Name | Description | +|------|-------------| +| [labels\_name](#output\_labels\_name) | The value of the name label | +| [name](#output\_name) | The name of the created namespace (from object metadata) | diff --git a/terraform/modules/eks-kubernetes-namespace/variables.tf b/terraform/modules/eks-kubernetes-namespace/variables.tf index e5a8500e..54bbc7aa 100644 --- a/terraform/modules/eks-kubernetes-namespace/variables.tf +++ b/terraform/modules/eks-kubernetes-namespace/variables.tf @@ -33,7 +33,6 @@ variable "limits" { { type = "Container" default = { - cpu = "150m" memory = "128Mi" } default_request = { From d99906905e44dbe7f0b328f3e7b9b209051f44f9 Mon Sep 17 00:00:00 2001 From: Max Glotov Date: Tue, 19 Dec 2023 17:00:01 +0600 Subject: [PATCH 2/2] updated FAQ --- docs/FAQ.md | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/FAQ.md b/docs/FAQ.md index 46b11996..dc9019c9 100644 --- a/docs/FAQ.md +++ b/docs/FAQ.md @@ -43,7 +43,6 @@ We strongly recommend using our terraform module `kubernetes-namespace` to manag { type = "Container" default = { - cpu = "150m" memory = "128Mi" } default_request = {