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

Add support for GRANT ... ON SEQUENCE #1171

Open
pigulla opened this issue May 24, 2024 · 0 comments
Open

Add support for GRANT ... ON SEQUENCE #1171

pigulla opened this issue May 24, 2024 · 0 comments
Labels
s: pending triage Pending Triage

Comments

@pigulla
Copy link
Contributor

pigulla commented May 24, 2024

Description

In our code we put emphasis on the Principle of Least Privilege. Consequently, we have to GRANT USAGE, SELECT ON SEQUENCE in various places.

Suggested solution

Not knowing much of the internals of pg-migrate, the interface arguably should look something like this:

pgm.grantOnSequences({
  roles: 'myrole',
  sequences: 'my_table_id_seq',
  privileges: ['SELECT', 'USAGE']
});

Alternative

No response

Additional context

No response

@pigulla pigulla added the s: pending triage Pending Triage label May 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
s: pending triage Pending Triage
Projects
None yet
Development

No branches or pull requests

1 participant