Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ALL privileges still not working for tables in postgres version => 17 #506

Open
amais33 opened this issue Jan 20, 2025 · 2 comments
Open

Comments

@amais33
Copy link

amais33 commented Jan 20, 2025

Related to @talbx works here: #339

I confirm that the issue is solved with postgres version under 17 for me.
But I still have the issue for "tables" with the version 17.
I think it's because of the new MAINTAIN privilege.
I found this 2 places where the list of tables privileges are present:

postgresql/helpers.go
postgresql/helpers_test.go
Maybe one need to add a test of postgres version and append the list with the MAINTAIN privilege if it's => 17, WDYT?

@talbx
Copy link
Contributor

talbx commented Feb 13, 2025

hey @amais33 I struggled reproducing your issue with PG 17. Could you provide a very minimal example IaC definition for me?

@amais33
Copy link
Author

amais33 commented Feb 17, 2025

Hey @talbx, thanks for looking into this issue.
Here’s a minimal example of an IaC definition:

resource "postgresql_default_privileges" "default_privileges" {
  database = "exampledb"
  role     = "exampleuser"
  schema   = "public"
  object_type = "table"
  privileges = ["ALL"]

  depends_on = [module.postgres]
}

Does this work for you?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants