我试图在本地运行helloworld gae-php程序,但在启动服务器时出错。
我的环境:
linux mint mate 17
php5.5
php-cgi5.5
python2.7.6
gae_php_1.9.17
当我尝试在gae本地启动web服务器时得到的错误信息:
INFO 2015-02-08 16:17:32,197 api_server.py:172] Starting API server at: http://localhost:54892
INFO 2015-02-08 16:17:32,201 dispatcher.py:186] Starting module "default" running at: http://localhost:8080
INFO 2015-02-08 16:17:32,202 admin_server.py:118] Starting admin server at: http://localhost:8000
ERROR 2015-02-08 16:17:33,204 php_runtime.py:227] The PHP runtime is not available
Traceback (most recent call last):
File "/mnt/star/program/gae/gae_php_1.9.17/google/appengine/tools/devappserver2/php_runtime.py", line 223, in new_instance
self._runtime_config_getter().application_root)
File "/mnt/star/program/gae/gae_php_1.9.17/google/appengine/tools/devappserver2/php_runtime.py", line 148, in _check_environment
'flag (%s) does not exist.' % php_executable_path)
_PHPBinaryError: The path specified with the --php_executable_path flag () does not exist.
有什么建议吗?
看起来您没有传递--php_executable_path
(默认情况下,它显示为空字符串)。运行:
dev_appserver.py --php_executable_path=/usr/bin/php-cgi yourapp
因此可能对您更有效。