码迷,mamicode.com
首页 > Web开发 > 详细

require_once(): Failed opening required '/var/www/config/config.php' (include_path='.:') in /var/www/vendor/forkiss/pharest/src/Pharest/Register/Register.php on line 10

时间:2019-06-18 20:13:39      阅读:287      评论:0      收藏:0      [点我收藏+]

标签:com   配置   环境   文件   ext   app   config   aliyun   ams   

环境

docker环境

错误

[Tue Jun 18 18:43:26 2019] 127.0.0.1:53980 [500]: /index.php - require_once(): Failed opening required '/var/www/config/config.php' (include_path='.:') in /var/www/vendor/forkiss/pharest/src/Pharest/Register/Register.php on line 10

原因

composer.json

升级 google/protobuf, grpc/grpc 出现以上错误 .无法加/var/www/config/config.php配置文件 , 而真实config目录为: /var/www/app/config/config.php

"require": {
        "php": ">=7.0.0",
        "ext-phalcon": ">=3.0.0",
        "forkiss/pharest": "~0.9",
        "ramsey/uuid": "~3.6",
        "aliyuncs/oss-sdk-php": "~2.2",
        "apache/thrift": "~0.10.0",
        "overtrue/wechat": "^3.3",
        "doctrine/cache": "1.6.*",
        "google/protobuf": "v3.1.0-alpha-1",
        "grpc/grpc": "^1.3"
    },

解决:

vim /var/www/vendor/forkiss/pharest/src/Pharest/Register/Register.php

//$config = new \Pharest\Config(require_once APP_ROOT . '/config/config.php');//原代码
   $config = new \Pharest\Config(require_once APP_ROOT . '/app/config/config.php'); //修改后的代码

require_once(): Failed opening required '/var/www/config/config.php' (include_path='.:') in /var/www/vendor/forkiss/pharest/src/Pharest/Register/Register.php on line 10

标签:com   配置   环境   文件   ext   app   config   aliyun   ams   

原文地址:https://www.cnblogs.com/300js/p/11047043.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!