1
0
mirror of https://github.com/terraform-aws-modules/terraform-aws-eks.git synced 2025-09-09 19:32:58 +08:00

feat: Add create_before_destroy lifecycle hook to security groups created (#1985)

This commit is contained in:
Bryant Biggs
2022-04-04 10:34:29 -04:00
committed by GitHub
parent 39a7c0c1f0
commit 6db89f8f20
4 changed files with 20 additions and 0 deletions
+4
View File
@@ -129,6 +129,10 @@ resource "aws_security_group" "cluster" {
{ "Name" = local.cluster_sg_name }, { "Name" = local.cluster_sg_name },
var.cluster_security_group_tags var.cluster_security_group_tags
) )
lifecycle {
create_before_destroy = true
}
} }
resource "aws_security_group_rule" "cluster" { resource "aws_security_group_rule" "cluster" {
+6
View File
@@ -372,6 +372,12 @@ resource "aws_security_group" "this" {
{ "Name" = local.security_group_name }, { "Name" = local.security_group_name },
var.security_group_tags var.security_group_tags
) )
# https://github.com/hashicorp/terraform-provider-aws/issues/2445
# https://github.com/hashicorp/terraform-provider-aws/issues/9692
lifecycle {
create_before_destroy = true
}
} }
resource "aws_security_group_rule" "this" { resource "aws_security_group_rule" "this" {
+6
View File
@@ -458,6 +458,12 @@ resource "aws_security_group" "this" {
}, },
var.security_group_tags var.security_group_tags
) )
# https://github.com/hashicorp/terraform-provider-aws/issues/2445
# https://github.com/hashicorp/terraform-provider-aws/issues/9692
lifecycle {
create_before_destroy = true
}
} }
resource "aws_security_group_rule" "this" { resource "aws_security_group_rule" "this" {
+4
View File
@@ -161,6 +161,10 @@ resource "aws_security_group" "node" {
}, },
var.node_security_group_tags var.node_security_group_tags
) )
lifecycle {
create_before_destroy = true
}
} }
resource "aws_security_group_rule" "node" { resource "aws_security_group_rule" "node" {