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

Revoke default privileges for new users #88

Open
ghost opened this issue Oct 9, 2020 · 5 comments
Open

Revoke default privileges for new users #88

ghost opened this issue Oct 9, 2020 · 5 comments
Labels
kind/question Questions about existing features

Comments

@ghost
Copy link

ghost commented Oct 9, 2020

New users actually can connect and create tables by default. I would like to know how can I do revoke with pulumi/postgresql. Thanks

@stack72
Copy link
Contributor

stack72 commented Oct 9, 2020

Is this what you are looking for? https://www.pulumi.com/docs/reference/pkg/postgresql/defaultprivileges/

@ghost
Copy link
Author

ghost commented Oct 9, 2020

hi @stack72 , DefaultPrivileges is working with object types: table, function, sequence, type) but not database. I tried to use Grant instead of DefaultPrivileges and it also doesn't seems to work correctly. Let me create simple repository to reproduce result easily.
I'm working with AWS RDS for Postgres if it is matter 😄

@SharpEdgeMarshall
Copy link

Same issue here, how can we revoke default PUBLIC role connect, temporary on Database?

@yann-soubeyrand
Copy link

Here is the link to the upstream issue regarding GRANT not working: cyrilgdn/terraform-provider-postgresql#133

@yann-soubeyrand
Copy link

Hello, I posted the solution I found on the upstream issue. In short, I had to set up a new PostgreSQL provider using the database owner’s credentials, which I used with postgresql.NewGrant().

@mikhailshilkov mikhailshilkov added the kind/question Questions about existing features label Aug 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/question Questions about existing features
Projects
None yet
Development

No branches or pull requests

4 participants