laravel5:chdir():没有这样的文件或目录(错误号2) [英] laravel5: chdir(): No such file or directory (errno 2)
问题描述
将基于laravel 5构建的网站部署到VPS服务器时遇到问题,但是在本地计算机上工作正常.
I have a problem when deploy website build on laravel 5 into VPS server, but on local machine it work fine.
我的页面是 http://easyway.vn/当前页面空白并显示错误
My page is http://easyway.vn/ current page display blank with error
无法加载资源:服务器的状态为500(内部服务器错误)
Failed to load resource: the server responded with a status of 500 (Internal Server Error)
我跑步时
php artisan serve --host = 0.0.0.0
php artisan serve --host=0.0.0.0
我有一个错误
[ErrorException]
chdir():没有这样的文件或目录(错误号2)
[ErrorException]
chdir(): No such file or directory (errno 2)
服务器信息
Server Info
OS:Linux 2.6
服务器版本:Apache/2.2.29(Unix)
PHP 5.4.41(CLI)(内置:2015年6月4日13:27:02) 版权所有(c)1997-2014 The PHP Group Zend Engine v2.4.0,版权所有(c)1998-2014 Zend Technologies
OS: Linux 2.6
Server version: Apache/2.2.29 (Unix)
PHP 5.4.41 (cli) (built: Jun 4 2015 13:27:02) Copyright (c) 1997-2014 The PHP Group Zend Engine v2.4.0, Copyright (c) 1998-2014 Zend Technologies
请帮助我!
推荐答案
这意味着您的Laravel应用程序找不到公用文件夹.
it means that your Laravel Application Can't Find the public folder.
我明白了它的作用
更改中:
chdir($this->laravel->publicPath());
在:
vendor/laravel/framework/src/Illuminate/Foundation/Console/ServeCommand.php
收件人:
chdir('/');
这篇关于laravel5:chdir():没有这样的文件或目录(错误号2)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!