Skip to content

Commit

Permalink
fix: Add missing Name tag to service security group (terraform-aws-…
Browse files Browse the repository at this point in the history
…modules#177)

* fix: Add missing Name tag in service sg

Signed-off-by: Lays Rodrigues <laysrodriguessilva@gmail.com>

* chore: Fix up ordering

---------

Signed-off-by: Lays Rodrigues <laysrodriguessilva@gmail.com>
Co-authored-by: Bryant Biggs <bryantbiggs@gmail.com>
  • Loading branch information
lays147 and bryantbiggs authored Mar 4, 2024
1 parent 62001b5 commit b3600de
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/antonbabenko/pre-commit-terraform
rev: v1.83.6
rev: v1.88.0
hooks:
- id: terraform_fmt
- id: terraform_wrapper_module_for_each
Expand Down
6 changes: 5 additions & 1 deletion modules/service/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -1320,7 +1320,11 @@ resource "aws_security_group" "this" {
description = var.security_group_description
vpc_id = data.aws_subnet.this[0].vpc_id

tags = merge(var.tags, var.security_group_tags)
tags = merge(
var.tags,
{ "Name" = local.security_group_name },
var.security_group_tags
)

lifecycle {
create_before_destroy = true
Expand Down

0 comments on commit b3600de

Please sign in to comment.