Skip to content

Commit

Permalink
feat: The operating_system option in the worker_pools input varia…
Browse files Browse the repository at this point in the history
…ble is now required. Allowed values are `REDHAT_8_64` or `RHCOS` (#340)
  • Loading branch information
Aayush-Abhyarthi authored Oct 14, 2024
1 parent 9fa184d commit dac1105
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ You need the following permissions to run this module.
| Name | Source | Version |
|------|--------|---------|
| <a name="module_observability_agents"></a> [observability\_agents](#module\_observability\_agents) | terraform-ibm-modules/observability-agents/ibm | 1.29.1 |
| <a name="module_ocp_base"></a> [ocp\_base](#module\_ocp\_base) | terraform-ibm-modules/base-ocp-vpc/ibm | 3.32.0 |
| <a name="module_ocp_base"></a> [ocp\_base](#module\_ocp\_base) | terraform-ibm-modules/base-ocp-vpc/ibm | 3.33.0 |

### Resources

Expand Down Expand Up @@ -233,7 +233,7 @@ No resources.
| <a name="input_verify_worker_network_readiness"></a> [verify\_worker\_network\_readiness](#input\_verify\_worker\_network\_readiness) | By setting this to true, a script will run kubectl commands to verify that all worker nodes can communicate successfully with the master. If the runtime does not have access to the kube cluster to run kubectl commands, this should be set to false. | `bool` | `true` | no |
| <a name="input_vpc_id"></a> [vpc\_id](#input\_vpc\_id) | The ID of the VPC to use. | `string` | n/a | yes |
| <a name="input_vpc_subnets"></a> [vpc\_subnets](#input\_vpc\_subnets) | Subnet metadata by VPC tier. | <pre>map(list(object({<br/> id = string<br/> zone = string<br/> cidr_block = string<br/> })))</pre> | n/a | yes |
| <a name="input_worker_pools"></a> [worker\_pools](#input\_worker\_pools) | List of worker pools | <pre>list(object({<br/> subnet_prefix = optional(string)<br/> vpc_subnets = optional(list(object({<br/> id = string<br/> zone = string<br/> cidr_block = string<br/> })))<br/> pool_name = string<br/> machine_type = string<br/> workers_per_zone = number<br/> resource_group_id = optional(string)<br/> operating_system = optional(string)<br/> labels = optional(map(string))<br/> minSize = optional(number)<br/> maxSize = optional(number)<br/> enableAutoscaling = optional(bool)<br/> boot_volume_encryption_kms_config = optional(object({<br/> crk = string<br/> kms_instance_id = string<br/> kms_account_id = optional(string)<br/> }))<br/> }))</pre> | <pre>[<br/> {<br/> "enableAutoscaling": true,<br/> "labels": {},<br/> "machine_type": "bx2.4x16",<br/> "maxSize": 3,<br/> "minSize": 1,<br/> "pool_name": "default",<br/> "subnet_prefix": "zone-1",<br/> "workers_per_zone": 2<br/> },<br/> {<br/> "enableAutoscaling": true,<br/> "labels": {<br/> "dedicated": "zone-2"<br/> },<br/> "machine_type": "bx2.4x16",<br/> "maxSize": 3,<br/> "minSize": 1,<br/> "pool_name": "zone-2",<br/> "subnet_prefix": "zone-2",<br/> "workers_per_zone": 2<br/> },<br/> {<br/> "enableAutoscaling": true,<br/> "labels": {<br/> "dedicated": "zone-3"<br/> },<br/> "machine_type": "bx2.4x16",<br/> "maxSize": 3,<br/> "minSize": 1,<br/> "pool_name": "zone-3",<br/> "subnet_prefix": "zone-3",<br/> "workers_per_zone": 2<br/> }<br/>]</pre> | no |
| <a name="input_worker_pools"></a> [worker\_pools](#input\_worker\_pools) | List of worker pools | <pre>list(object({<br/> subnet_prefix = optional(string)<br/> vpc_subnets = optional(list(object({<br/> id = string<br/> zone = string<br/> cidr_block = string<br/> })))<br/> pool_name = string<br/> machine_type = string<br/> workers_per_zone = number<br/> resource_group_id = optional(string)<br/> operating_system = string<br/> labels = optional(map(string))<br/> minSize = optional(number)<br/> maxSize = optional(number)<br/> enableAutoscaling = optional(bool)<br/> boot_volume_encryption_kms_config = optional(object({<br/> crk = string<br/> kms_instance_id = string<br/> kms_account_id = optional(string)<br/> }))<br/> }))</pre> | <pre>[<br/> {<br/> "enableAutoscaling": true,<br/> "labels": {},<br/> "machine_type": "bx2.4x16",<br/> "maxSize": 3,<br/> "minSize": 1,<br/> "operating_system": "REDHAT_8_64",<br/> "pool_name": "default",<br/> "subnet_prefix": "zone-1",<br/> "workers_per_zone": 2<br/> },<br/> {<br/> "enableAutoscaling": true,<br/> "labels": {<br/> "dedicated": "zone-2"<br/> },<br/> "machine_type": "bx2.4x16",<br/> "maxSize": 3,<br/> "minSize": 1,<br/> "operating_system": "REDHAT_8_64",<br/> "pool_name": "zone-2",<br/> "subnet_prefix": "zone-2",<br/> "workers_per_zone": 2<br/> },<br/> {<br/> "enableAutoscaling": true,<br/> "labels": {<br/> "dedicated": "zone-3"<br/> },<br/> "machine_type": "bx2.4x16",<br/> "maxSize": 3,<br/> "minSize": 1,<br/> "operating_system": "REDHAT_8_64",<br/> "pool_name": "zone-3",<br/> "subnet_prefix": "zone-3",<br/> "workers_per_zone": 2<br/> }<br/>]</pre> | no |

### Outputs

Expand Down
2 changes: 2 additions & 0 deletions examples/end-to-end-example/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ variable "worker_pools" {
subnet_prefix = string
pool_name = string
machine_type = string
operating_system = string
workers_per_zone = number
resource_group_id = optional(string)
labels = optional(map(string))
Expand All @@ -54,6 +55,7 @@ variable "worker_pools" {
subnet_prefix = "zone-1"
pool_name = "default" # ibm_container_vpc_cluster automatically names default pool "default" (See https://github.com/IBM-Cloud/terraform-provider-ibm/issues/2849)
machine_type = "bx2.4x16"
operating_system = "REDHAT_8_64"
workers_per_zone = 3
minSize = 1
maxSize = 5
Expand Down
2 changes: 1 addition & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ locals {

module "ocp_base" {
source = "terraform-ibm-modules/base-ocp-vpc/ibm"
version = "3.32.0"
version = "3.33.0"
cluster_name = var.cluster_name
ocp_version = var.ocp_version
resource_group_id = var.resource_group_id
Expand Down
5 changes: 4 additions & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ variable "worker_pools" {
machine_type = string
workers_per_zone = number
resource_group_id = optional(string)
operating_system = optional(string)
operating_system = string
labels = optional(map(string))
minSize = optional(number)
maxSize = optional(number)
Expand All @@ -92,6 +92,7 @@ variable "worker_pools" {
subnet_prefix = "zone-1"
pool_name = "default" # ibm_container_vpc_cluster automatically names default pool "default" (See https://github.com/IBM-Cloud/terraform-provider-ibm/issues/2849)
machine_type = "bx2.4x16"
operating_system = "REDHAT_8_64"
workers_per_zone = 2
minSize = 1
maxSize = 3
Expand All @@ -102,6 +103,7 @@ variable "worker_pools" {
subnet_prefix = "zone-2"
pool_name = "zone-2"
machine_type = "bx2.4x16"
operating_system = "REDHAT_8_64"
workers_per_zone = 2
minSize = 1
maxSize = 3
Expand All @@ -112,6 +114,7 @@ variable "worker_pools" {
subnet_prefix = "zone-3"
pool_name = "zone-3"
machine_type = "bx2.4x16"
operating_system = "REDHAT_8_64"
workers_per_zone = 2
minSize = 1
maxSize = 3
Expand Down

0 comments on commit dac1105

Please sign in to comment.