monca
monca

Reputation: 41

unable to install RPostgreSQL in rstudio-server docker container to connect to postgres

I have a rstudio-server docker container (R-server) and a postgres docker container (Pg), and am using rstudio-server to connect to postgres database via RPostgreSQL package. However, I can't install RPostgreSQL package on R-server, and don't want to install a postgres db on R either. Is there any method to solve the problem?

The error message of installing RPostgreSQL is

"libpq-fe.h: No such file or directory"

and I think this is due to I have no postgres installed on R-server. I tried to install libqp-dev and a lot of depending error occurs.

Can anyone give me simple solutions? Thanks!

Upvotes: 4

Views: 770

Answers (1)

radhikesh93
radhikesh93

Reputation: 940

had the same issue, just need to install. Found it here, towards the end.

sudo apt-get install libpq-dev

Upvotes: 3

Related Questions