Skip to content

Commit 69ad346

Browse files
feat: Add support for deletion protection functionality in the cluster
1 parent d97712a commit 69ad346

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

main.tf

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ resource "aws_eks_cluster" "this" {
4242
role_arn = local.role_arn
4343
version = var.kubernetes_version
4444
enabled_cluster_log_types = var.enabled_log_types
45+
enable_deletion_protection = var.enable_deletion_protection
4546
bootstrap_self_managed_addons = false
4647
force_update_version = var.force_update_version
4748

variables.tf

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,12 @@ variable "enabled_log_types" {
4444
default = ["audit", "api", "authenticator"]
4545
}
4646

47+
variable "enable_deletion_protection" {
48+
description = "Whether to enable deletion protection for the EKS cluster"
49+
type = bool
50+
default = false
51+
}
52+
4753
variable "force_update_version" {
4854
description = "Force version update by overriding upgrade-blocking readiness checks when updating a cluster"
4955
type = bool

0 commit comments

Comments
 (0)