Cpanel can't install psycopg2

Viewed 18

Been trying to install psycopg2 on a client's Cpanel but every time I try, I get the following message:

  Error: pg_config executable not found.

  pg_config is required to build psycopg2 from source.  Please add the directory
  containing pg_config to the $PATH or specify the full executable path with the
  option:

      python setup.py build_ext --pg-config /path/to/pg_config build ...

  or with the pg_config option in 'setup.cfg'.

  If you prefer to avoid building psycopg2 from source, please install the PyPI
  'psycopg2-binary' package instead.

  For further information please check the 'doc/src/install.rst' file (also at
  <https://www.psycopg.org/docs/install.html>).

  [end of output]

As far as I've seen, for production, you shouldn't use psycopg2-binary, but then psycopg2 doesn't give me many options.

The Cpanel has PostgreSQL installed, and it even has phpPgAdmin. I tried seeing a lot of videos and questions done here on this platform but haven't found anything.

Any solution to this?

0 Answers
Related