Skip to content

Commit

Permalink
feat: Define default name for VPC endpoint (#1151)
Browse files Browse the repository at this point in the history
* feat: Define default name for VPC endpoint

* Change default name

Co-authored-by: Bryant Biggs <[email protected]>

* Remove not require qoute

* fix: Go back to key

---------

Co-authored-by: Bryant Biggs <[email protected]>
  • Loading branch information
sebastianczech and bryantbiggs authored Dec 18, 2024
1 parent 9ffd9c6 commit 41348d3
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.96.1
rev: v1.96.2
hooks:
- id: terraform_fmt
- id: terraform_docs
Expand Down
6 changes: 5 additions & 1 deletion modules/vpc-endpoints/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,11 @@ resource "aws_vpc_endpoint" "this" {
}
}

tags = merge(var.tags, try(each.value.tags, {}))
tags = merge(
var.tags,
{ "Name" = replace(each.key, ".", "-") },
try(each.value.tags, {}),
)

timeouts {
create = try(var.timeouts.create, "10m")
Expand Down

0 comments on commit 41348d3

Please sign in to comment.