Skip to content

Commit

Permalink
chore: support passing talos api version contract
Browse files Browse the repository at this point in the history
Support passing talos api version contract.

Also bump deps.

Signed-off-by: Noel Georgi <[email protected]>
  • Loading branch information
frezbo committed Feb 22, 2024
1 parent bda0542 commit 669f44a
Show file tree
Hide file tree
Showing 5 changed files with 23 additions and 14 deletions.
1 change: 1 addition & 0 deletions examples/terraform/aws/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
| <a name="input_kubernetes_api_allowed_cidr"></a> [kubernetes\_api\_allowed\_cidr](#input\_kubernetes\_api\_allowed\_cidr) | The CIDR from which to allow to access the Kubernetes API | `string` | `"0.0.0.0/0"` | no |
| <a name="input_kubernetes_version"></a> [kubernetes\_version](#input\_kubernetes\_version) | Kubernetes version to use for the cluster, if not set the k8s version shipped with the talos sdk version will be used | `string` | `null` | no |
| <a name="input_talos_api_allowed_cidr"></a> [talos\_api\_allowed\_cidr](#input\_talos\_api\_allowed\_cidr) | The CIDR from which to allow to access the Talos API | `string` | `"0.0.0.0/0"` | no |
| <a name="input_talos_version_contract"></a> [talos\_version\_contract](#input\_talos\_version\_contract) | Talos API version to use for the cluster, if not set the the version shipped with the talos sdk version will be used | `string` | `null` | no |
| <a name="input_vpc_cidr"></a> [vpc\_cidr](#input\_vpc\_cidr) | The IPv4 CIDR block for the VPC. | `string` | `"172.16.0.0/16"` | no |
| <a name="input_worker_groups"></a> [worker\_groups](#input\_worker\_groups) | List of node worker node groups to create | <pre>list(object({<br> name = string<br> instance_type = optional(string, "c5.large")<br> ami_id = optional(string, null)<br> num_instances = optional(number, 1)<br> config_patch_files = optional(list(string), [])<br> tags = optional(map(string), {})<br> }))</pre> | <pre>[<br> {<br> "name": "default"<br> }<br>]</pre> | no |

Expand Down
2 changes: 2 additions & 0 deletions examples/terraform/aws/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -312,6 +312,7 @@ data "talos_machine_configuration" "controlplane" {
cluster_endpoint = "https://${module.elb_k8s_elb.elb_dns_name}"
machine_type = "controlplane"
machine_secrets = talos_machine_secrets.this.machine_secrets
talos_version = var.talos_version_contract
kubernetes_version = var.kubernetes_version
docs = false
examples = false
Expand All @@ -330,6 +331,7 @@ data "talos_machine_configuration" "worker_group" {
cluster_endpoint = "https://${module.elb_k8s_elb.elb_dns_name}"
machine_type = "worker"
machine_secrets = talos_machine_secrets.this.machine_secrets
talos_version = var.talos_version_contract
kubernetes_version = var.kubernetes_version
docs = false
examples = false
Expand Down
6 changes: 6 additions & 0 deletions examples/terraform/aws/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ variable "ccm" {
default = false
}

variable "talos_version_contract" {
description = "Talos API version to use for the cluster, if not set the the version shipped with the talos sdk version will be used"
type = string
default = null
}

variable "kubernetes_version" {
description = "Kubernetes version to use for the cluster, if not set the k8s version shipped with the talos sdk version will be used"
type = string
Expand Down
26 changes: 13 additions & 13 deletions examples/terraform/azure/.terraform.lock.hcl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion examples/terraform/azure/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Getting the kubeconfig and talosconfig for this cluster can be done with `terraf
| Name | Version |
|------|---------|
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.85.0 |
| <a name="provider_azurerm"></a> [azurerm](#provider\_azurerm) | 3.92.0 |
| <a name="provider_talos"></a> [talos](#provider\_talos) | 0.3.2 |
## Modules
Expand Down

0 comments on commit 669f44a

Please sign in to comment.