Skip to content
Open
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
6 changes: 3 additions & 3 deletions getting-started/eks-terraform/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ data "aws_ami" "edera_protect" {
filter {
name = "name"
values = [
"edera-protect-v1.*-al2023-amazon-eks-node-${local.cluster_version}-*"
"edera-protect-*-al2023-amazon-eks-${var.hypervisor}-node-${local.cluster_version}-*"
]
}

Expand Down Expand Up @@ -118,7 +118,7 @@ module "eks" {
edera_protect = {
name = local.node_group_name

# Use Edera AMI
# Use Edera AMI (selected by hypervisor variable)
ami_id = data.aws_ami.edera_protect.id
ami_type = "AL2023_x86_64_STANDARD"

Expand Down Expand Up @@ -156,4 +156,4 @@ module "eks" {
Environment = "edera-learn"
Project = "edera-eks-example"
}
}
}
9 changes: 8 additions & 1 deletion getting-started/eks-terraform/terraform.tfvars.example
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,22 @@ edera_account_id = "REPLACE_WITH_EDERA_ACCOUNT_ID"
cluster_name = "edera-cluster"
cluster_version = "1.35"

# Optional: Hypervisor backend — "xen" (default, production) or "kvm" (Early Access)
# hypervisor = "xen"

# Optional: AWS region (Edera AMIs only available in us-west-2 and us-gov-west-1)
region = "us-west-2"

# Optional: Node group configuration
# For Xen, any supported instance type works:
instance_types = ["m5n.xlarge"]
# For KVM, use a metal instance or a nested-virtualization-capable type:
# instance_types = ["m7i.xlarge"]
# Supported KVM families: C8i, M8i, R8i, C7i, M7i, R7i (and variants), or any *.metal type
desired_size = 2
min_size = 1
max_size = 3

# Optional: SSH access to worker nodes (default: disabled)
# enable_ssh_access = true
# ssh_key_name = "my-ec2-keypair"
# ssh_key_name = "my-ec2-keypair"
17 changes: 14 additions & 3 deletions getting-started/eks-terraform/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,22 @@ variable "cluster_name" {
variable "cluster_version" {
description = "Kubernetes version to use for the EKS cluster"
type = string
default = "1.32"
default = "1.35"
}

variable "hypervisor" {
description = "Hypervisor backend to use: 'xen' (default, production) or 'kvm' (Early Access). Determines which Edera AMI is selected."
type = string
default = "xen"

validation {
condition = contains(["xen", "kvm"], var.hypervisor)
error_message = "hypervisor must be 'xen' or 'kvm'."
}
}

variable "instance_types" {
description = "List of instance types associated with the EKS Node Group"
description = "List of instance types for the EKS Node Group. For KVM, use a metal instance or a nested-virtualization-capable type (e.g. m7i.xlarge, c7i.xlarge). For Xen, any supported type works."
type = list(string)
default = ["m5n.xlarge"]
}
Expand Down Expand Up @@ -62,4 +73,4 @@ variable "ssh_key_name" {
description = "Name of the EC2 Key Pair for SSH access to worker nodes (required if enable_ssh_access is true)"
type = string
default = ""
}
}