From: <php...@li...> - 2012-08-28 06:15:39
|
Hi Ruggero, What we are doing is running apache with php-fpm on one server and tomcat 6 with PHP/Java bridge on another server. It is working great and without any issues. The only thing you have to do is to define the constant JAVA_HOSTS on the PHP script side and point it to your java server: define('JAVA_HOSTS', 'http://someserver:8080'); After defining the constant include the Java.inc script and it should work as expected. (Dont forget to open the needed ports on the java server firewall - be sure that the java bridge is not exposed to the internet but only to the php server. Check the security considerations on pjb readme: http://php-java-bridge.cvs.sourceforge.net/viewvc/php-java-bridge/php-java-bridge/README?view=markup ) Regards, Diego Hi, I have successfully installed PHP/Java Bridge on a Ubuntu 12.04 64 bit > server with Tomcat and php-cgi; all examples are running OK. > I would like though now to run PHP code on a separate Ubuntu 12.04 64 bit > LAMP server, accessing Java classes on the Tomcat server. > Can anyone help, thank you very much: > - Is this possible? > - Do I have to modify the Java.inc include file (and/or the JavaProxy.php > file) ? > - Does the Java.inc (and/or the JavaProxy.php file) file have to be on the > LAMP or on the Tomcat server? > - Do I have to open any port on the Tomcat server? > - Do I still have to run PHP as a CGI service? > Ruggero Domenichini (rujero) -- ---------------------------------------- Diego Sainz Solutions Development Sperantus USA: 619-994-3431 / MEX: 646-1246609 http://www.sperantus.com twitter.com/sperantus facebook.com/sperantus |