2016-11-14 84 views
0

我使用Laravel制作了多个网络应用程序,所以这不是我的第一个生产deply。然而 - 我遇到了一个奇怪的问题,我似乎无法找到答案。与我迄今为止所做的所有应用程序一样 - 我将所有文件复制/粘贴到生产服务器,在config文件夹中设置.env文件,编辑app.php和database.php,但我一直收到此错误:Filesystem.php - 无法打开流

ErrorException in ClassLoader.php line 412: 
    include(/home/xxxxx/public_html/appname/vendor/composer/../laravel/framework/src/Illuminate/Filesystem/Filesystem.php): 
    failed to open stream: No such file or directory 
    in ClassLoader.php line 412 
at HandleExceptions->handleError('2', 'include(/home/xxxxx/public_html/appname/vendor/composer/../laravel/framework/src/Illuminate/Filesystem/Filesystem.php): failed to open stream: No such file or directory', '/home/xxxxx/public_html/appname/vendor/composer/ClassLoader.php', '412', array('file' => '/home/xxxxx/public_html/appname/vendor/composer/../laravel/framework/src/Illuminate/Filesystem/Filesystem.php')) in ClassLoader.php line 412 
at Composer\Autoload\includeFile() in ClassLoader.php line 412 
at Composer\Autoload\includeFile('/home/xxxxx/public_html/appname/vendor/composer/../laravel/framework/src/Illuminate/Filesystem/Filesystem.php') in ClassLoader.php line 301 
at ClassLoader->loadClass('Illuminate\Filesystem\Filesystem') 
at spl_autoload_call('Illuminate\Filesystem\Filesystem') in Application.php line 539 
at Application->registerConfiguredProviders() in RegisterProviders.php line 17 
at RegisterProviders->bootstrap(object(Application)) in Application.php line 203 
at Application->bootstrapWith(array('Illuminate\Foundation\Bootstrap\DetectEnvironment', 'Illuminate\Foundation\Bootstrap\LoadConfiguration', 'Illuminate\Foundation\Bootstrap\ConfigureLogging', 'Illuminate\Foundation\Bootstrap\HandleExceptions', 'Illuminate\Foundation\Bootstrap\RegisterFacades', 'Illuminate\Foundation\Bootstrap\RegisterProviders', 'Illuminate\Foundation\Bootstrap\BootProviders')) in Kernel.php line 253 
at Kernel->bootstrap() in Kernel.php line 144 
at Kernel->sendRequestThroughRouter(object(Request)) in Kernel.php line 116 
at Kernel->handle(object(Request)) in index.php line 54 

现在...我已经尝试了我在网上找到的所有东西。清理缓存,检查文件权限,运行作曲者转储自动加载,重新上传所有文件 - 但似乎没有任何帮助。这是一个PHP v5.6的共享主机,它已经有几个laravel应用程序在运行,并且它们完美地工作。唯一的区别是这个是laravel 5.3,另一个是5.2。

我在我的本地开发机器上没有错误。

任何想法!?

+0

您是否尝试删除/ vendor目录并在共享主机上运行'composer install'? – ktross

+0

我知道你说你尝试过,但听起来像是许可问题。你有没有尝试过使用git,也许伪造你的部署? – Wistar

+0

证明这是一些安全功能,它在主机本身上处于活动状态。由于某种原因,所提到的类被标记为恶意软件,并且在不同时间段内不断删除。所以有时应用程序根本无法工作,有时甚至会在几秒/分钟后停止工作。 由于我的FTP客户端从来没有刷新自己 - 它总是显示文件正确的位置。我联系了托管公司,他们解决了这个问题。 – Skipp

回答

0

这可能是由于某些安全功能在Web托管本身上处于活动状态。所提到的类被标记为恶意软件,并且AV在上载/重新上传时会不断删除它。由于整个文件/类缺失 - 应用程序会抛出提到的错误。

如果您不运行自己的服务器,并且无法列出白名单,只需联系您的托管服务提供商为您做。

相关问题