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

Non-privileged user for most interactions #140

Open
danielbrauer opened this issue Feb 24, 2021 · 0 comments
Open

Non-privileged user for most interactions #140

danielbrauer opened this issue Feb 24, 2021 · 0 comments

Comments

@danielbrauer
Copy link
Owner

These bits might help in the migrations, although probably best to do it explicitly:

ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO ${client.escapeIdentifier(user)};
ALTER DEFAULT PRIVILEGES IN SCHEMA public REVOKE SELECT ON TABLES FROM read_only_user;
GRANT SELECT ON ALL TABLES IN SCHEMA public TO ${client.escapeIdentifier(user)};
REVOKE ALL PRIVILEGES ON ALL TABLES IN SCHEMA public FROM read_only_user;

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

1 participant