Skip to content

dapperlabs-platform/terraform-postgres-grants

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Example

module "postgres_waterhose-admin" {
  source           = "github.com/dapperlabs-platform/terraform-postgres-grants?ref={ref}"
  database         = "the-database"
  role             = "the-database-role"
  tables           = ["tables", "go", "here"]
  table_privileges = ["SELECT", "INSERT", "UPDATE", "DELETE"]
  users            = ["[email protected]"]
}

Requirements

Name Version
terraform >= 0.13
postgresql 1.19.0

Providers

Name Version
postgresql 1.19.0

Modules

No modules.

Resources

Name Type
postgresql_grant.database_grant resource
postgresql_grant.table_grant resource
postgresql_grant_role.user_role_grant_role resource
postgresql_role.the_role resource

Inputs

Name Description Type Default Required
database Database this applies to string n/a yes
database_privileges Privileges to apply to the database list(string)
[
"CONNECT"
]
no
role Name of the role to create string n/a yes
schema Table schema string "public" no
table_privileges Privileges to apply to tables in the database list(string) n/a yes
tables Tables in the database list(string) n/a yes
users Users who need access to the database and tables list(string) n/a yes

Outputs

No outputs.