【问题标题】:How to deploy CakePHP-application on CentOS?如何在 CentOS 上部署 CakePHP 应用程序?
【发布时间】:2013-07-10 13:18:48
【问题描述】:

我几乎设法在 CentOS 服务器上部署了一个 CakePHP 应用程序,但它仍然需要很少的配置。我在 /etc/httpd/conf/httpd.conf 中启用了 mod_rewrite 并重新启动了 apache-server。

然后我将 Cake 核心库放在 /home/user/cakephp-core/ 中

当我尝试通过网络浏览器访问此页面时,我收到消息“500 内部错误”。

在 apache-logs 中我发现了以下消息:

PHP Warning:  include(/$HOME/cakephp-core/lib/Cake/bootstrap.php): failed to open stream: Permission denied in /srv/www/site/public_html/main/index.php on line 96
PHP Warning:  include(): Failed opening '/$HOME/cakephp-core/lib/Cake/bootstrap.php' for inclusion (include_path='.:/usr/share/pear:/usr/share/php') in /srv/www/site/public_html/main/index.php on line 96
PHP Fatal error:  CakePHP core could not be found. Check the value of CAKE_CORE_INCLUDE_PATH in APP/webroot/index.php. It should point to the directory containing your /cake core directory and your /vendors root directory. in /srv/www/site/public_html/main/index.php on line 101

它说的是“权限被拒绝”......我应该向谁授予权限以及在哪里?我把“apache:apache”给了 tmp/-folder……有什么想法吗?

【问题讨论】:

    标签: cakephp centos


    【解决方案1】:

    只需阅读日志并尝试理解它。

    它非常清楚地告诉您什么权限不足。 linux 设置权限的命令是chmod。正如文本已经告诉您的那样,您还想确保您的 CakePHP 核心包含路径是正确的。仔细检查一下。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2023-03-03
      • 1970-01-01
      • 2021-11-28
      • 1970-01-01
      • 1970-01-01
      • 2016-01-24
      • 2010-10-11
      相关资源
      最近更新 更多