feat: Add Autoscaling schedule for EKS managed node group (#2504)

Co-authored-by: Bryant Biggs <bryantbiggs@gmail.com>
This commit is contained in:
Le Minh Duc
2023-03-31 21:46:27 +07:00
committed by GitHub
parent 2cf6a5bc14
commit 4a2523cddd
8 changed files with 78 additions and 3 deletions

View File

@@ -680,7 +680,7 @@ resource "aws_autoscaling_group" "this" {
################################################################################
resource "aws_autoscaling_schedule" "this" {
for_each = var.create && var.create_schedule ? var.schedules : {}
for_each = { for k, v in var.schedules : k => v if var.create && var.create_schedule }
scheduled_action_name = each.key
autoscaling_group_name = aws_autoscaling_group.this[0].name

View File

@@ -82,7 +82,7 @@ output "autoscaling_group_vpc_zone_identifier" {
}
################################################################################
# autoscaling group schedule
# Autoscaling Group Schedule
################################################################################
output "autoscaling_group_schedule_arns" {