Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: port volume type feature #78

Merged
merged 4 commits into from
Jul 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions modules/eks/eks.tf
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ locals {
"instance_type" : worker.instance_type,
"tags" : [for tag_key, tag_value in merge(merge(local.default_node_tags, var.tags), worker.tags) : { "key" : tag_key, "value" : tag_value, "propagate_at_launch" : true }],
"volume_size" : worker.volume_size,
"volume_type" : worker.volume_type != null ? worker.volume_type : "gp2",
"subnetworks" : worker.subnetworks != null ? worker.subnetworks : var.subnetworks
"eks_target_group_arns" : worker.eks_target_group_arns
"bootstrap_extra_args" : "%{if lookup(worker, "max_pods", null) != null}--use-max-pods false%{endif} %{if lookup(worker, "container_runtime", null) == "containerd"}--container-runtime containerd %{endif}",
Expand All @@ -40,6 +41,7 @@ EOT
asg_min_size = lookup(node_pool, "min_size")
instance_type = lookup(node_pool, "instance_type")
root_volume_size = lookup(node_pool, "volume_size")
root_volume_type = lookup(node_pool, "volume_type")
target_group_arns = lookup(node_pool, "eks_target_group_arns")
key_name = aws_key_pair.nodes.key_name
public_ip = false
Expand Down
1 change: 1 addition & 0 deletions modules/eks/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ variable "node_pools" {
spot_instance = optional(bool)
max_pods = optional(number) # null to use default upstream configuration
volume_size = number
volume_type = optional(string)
subnetworks = list(string) # null to use default upstream configuration
labels = map(string)
taints = list(string)
Expand Down