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

modify code to not require postgres user to be superuser #31

Open
allan-simon opened this issue Dec 22, 2017 · 2 comments
Open

modify code to not require postgres user to be superuser #31

allan-simon opened this issue Dec 22, 2017 · 2 comments

Comments

@allan-simon
Copy link
Owner

currently due to the fact we create the extension uuid, we need to grant the db user, superuser privilege, which is not optimal in term of security

need to check if we can avoid this with a "create extension if not exist"

@jean553
Copy link
Collaborator

jean553 commented Dec 30, 2017

Hmmm... not sure I get it. I think you're talking about the final environment (not the dev vagrant one). So I guess this line connection.execute("CREATE EXTENSION IF NOT EXISTS \"uuid-ossp\"", &[]).unwrap(); throws an error during the execution. Right ?

@allan-simon
Copy link
Owner Author

you're right.

In vagrant's one it works because our dev environment actually does not reflect a real environment (which is bad) , in which you will not grant superuser privilege to the db user used by the application code.

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