Skip to content

[Feature Request] When changing owner of database, change ownership of all objects by providing an additional flag #439

Closed
@lukaalba

Description

@lukaalba

Hi there,

I would like to request an additional flag for the postgresql_database-resource. Although it is possible to change the owner of the database itself with this resource, the owner of already created tables or sequences in this database is not altered. I would like to suggest an additional flag to be able to alter those objects, too, e.g.:

Terraform Configuration Files

resource "postgresql_database" "my_db" {
  name              = "my_db"
  owner             = "my_role"
  template          = "template0"
  lc_collate        = "C"
  connection_limit  = -1
  allow_connections = true
  alter_object_ownership = true
}

If this feature request turns out to be useful, I am happy to provide a PR.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions