27 lines
761 B
HCL
27 lines
761 B
HCL
output "database" {
|
|
description = "Database name"
|
|
value = var.tenant_name
|
|
}
|
|
|
|
output "username" {
|
|
description = "Database username"
|
|
value = var.tenant_name
|
|
}
|
|
|
|
output "password" {
|
|
description = "Database password"
|
|
value = random_password.tenant_password.result
|
|
sensitive = true
|
|
}
|
|
|
|
output "connection_string" {
|
|
description = "PostgreSQL connection string"
|
|
value = "postgresql://${var.tenant_name}:${random_password.tenant_password.result}@localhost:${var.target_port}/${var.tenant_name}"
|
|
sensitive = true
|
|
}
|
|
|
|
output "installed" {
|
|
description = "Installation complete flag"
|
|
value = true
|
|
depends_on = [postgresql_role.role, postgresql_grant.grant, postgresql_database.db, random_password.tenant_password]
|
|
} |