V8js not working with dreamfactory on debian 9.1


#1

Does anyone know how to get v8js installed and working with dreamfactory on debian 9.1 64-bit?

I’m trying to work through the custom script example with v8js here. I’ve installed dreamfactory from git using php7 on debian 9.1 64-bit. When I go to the API docs and try the API out, I get the following error: “This instance cannot run server-side javascript scripts. The ‘v8js’ is not available.”

I’ve tried building and installing v8js as described here, but this does not solve the issue. v8js also does not show up when running php -m, although I’ve added extension=v8js.so to the php.ini file for both the cli and php7.0-fpm.

Luckily the Bitnami installation seems to work, but I would like to know how to install it myself if possible.

Any help much appreciated.

Thanks!


#2

You need to compile the v8 extension by yourself.

Here is a link to the Dreamfactory wiki page which tells you how to do that.


#3

Thank you for the link. This does work for Ubuntu, and I can use that if necessary. Are there install instructions for Debian specifically? I followed the instructions on installing v8js here (https://github.com/phpv8/v8js/blob/php7/README.Linux.md). I compiled v8 fine, however v8js stopped at ./configure --with-v8js=/opt/v8 with the following error:
checking for V8 version... NONE
configure: error: could not determine libv8 version

So it seems there’s an issue with installing on Debian 9.1, any ideas how to fix it?


#4

I just tried this on Ubuntu yet and it worked without any errors. Maybe you can use other resources to find the answer for your problem.