Conkel Conkel
Conkel Conkel

Reputation: 11

Root privilege can connect to postgresql db via node, but other cannot

For setting the wiki.js onto my linux server(ubuntu 20.04), I followed steps with url below.

wiki.js installation guide

Following to installation process, starting temporary web with node server root can connect to database but other user cannot.

How can I grant the right privilidge to user that named wikijs or nobody (or else)?

And I attach a picture of the symptoms above.

node server with wikijs user. enter image description here

node server with root user. enter image description here

If you need more information, please let me know with comments. Thanks!

Upvotes: 0

Views: 33

Answers (1)

Conkel Conkel
Conkel Conkel

Reputation: 11

I got a solution for it.

The problem is cannot resolve the "localhost", and it is so beacaue of the /etc/hosts has 600 permission.

So, I changed the /etc/hosts permission to 644.

Upvotes: 0

Related Questions