Skip to content
This repository has been archived by the owner on Sep 27, 2024. It is now read-only.

BATIAI-2423-fix-lambda role: Adding a condition for deploying delete_ebs_lambda_role access entry #150

Merged
merged 2 commits into from
May 8, 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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
## 16.0.0
* upgrade to EKS module 20.8.5
* introducing eks access entries
* updating delete_ebs_role dependency

## 15.0.0
* Upgrade to EKS 1.28
Expand Down
4 changes: 2 additions & 2 deletions eks-access-entries.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ resource "aws_eks_access_policy_association" "cluster_admin" {

## Creating access entry for delete_ebs_volumes_lambda with namespaced adminpolicy
resource "aws_eks_access_entry" "delete_ebs_volume" {

count = var.delete_ebs_volume_role_arn != "" ? 1 : 0
cluster_name = local.name
kubernetes_groups = []
principal_arn = var.delete_ebs_volume_role_arn
Expand All @@ -51,7 +51,7 @@ resource "aws_eks_access_entry" "delete_ebs_volume" {
]
}
resource "aws_eks_access_policy_association" "delete_ebs_volume" {

count = var.delete_ebs_volume_role_arn != "" ? 1 : 0
access_scope {
namespaces = ["batcave"]
type = "namespace"
Expand Down
Loading