Skip to content

Commit 4bc7180

Browse files
authored
Replaces it with the updated list-compatible syntax (#10)
* Replaces it with the updated list-compatible syntax * local testing of terratest * local testing of terratest * local testing of terratest * local testing of terratest * local testing of terratest * updating hello world test * dropping the test due to its not following the testing pattern
1 parent 6e9ed85 commit 4bc7180

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/modules/postgresql-user/main.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ locals {
22
enabled = module.this.enabled
33

44
db_user = length(var.db_user) > 0 ? var.db_user : var.service_name
5-
db_password = length(var.db_password) > 0 ? var.db_password : join("", random_password.db_password.*.result)
5+
db_password = length(var.db_password) > 0 ? var.db_password : join("", random_password.db_password[*].result)
66

77
save_password_in_ssm = local.enabled && var.save_password_in_ssm
88

@@ -45,7 +45,7 @@ resource "postgresql_role" "default" {
4545
# Apply the configured grants to the user
4646
resource "postgresql_grant" "default" {
4747
count = local.enabled ? length(var.grants) : 0
48-
role = join("", postgresql_role.default.*.name)
48+
role = join("", postgresql_role.default[*].name)
4949
database = var.grants[count.index].db
5050
schema = var.grants[count.index].schema
5151
object_type = var.grants[count.index].object_type

src/outputs.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ output "additional_schemas" {
1616
output "additional_grants" {
1717
value = keys(module.additional_grants)
1818
description = "Additional grants"
19-
}
19+
}

0 commit comments

Comments
 (0)