未创建 laravel services.json
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/23336579/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
laravel services.json not created
提问by nonsenz
Sometimes my services.json
is missing after running composer update
or php artisan clear-compiled
.
有时我services.json
在运行composer update
或php artisan clear-compiled
.
I checked the permissions and even changed it to 777 on the storage folder but it does not help. How can I debug whats wrong?
我检查了权限,甚至在存储文件夹上将其更改为 777,但没有帮助。我该如何调试出了什么问题?
There are no entries in my laravel log and nothing in my apache log. I'm using "laravel/framework": "4.1.*"
我的 laravel 日志中没有条目,我的 apache 日志中也没有任何条目。我正在使用“laravel/framework”:“4.1.*”
回答by sergiovilar
Just run a php artisan serve
and stop, this will create the services.json file.
只需运行php artisan serve
并停止,这将创建 services.json 文件。
回答by Joel Davey
Ensure your web server has access to the files/folders specifically app/storage/meta/services.json if this file/folder is not there create it and add some json to see if you can accesss it in the browser. If forbidden/denied see permissions below:
确保您的 Web 服务器可以访问文件/文件夹,特别是 app/storage/meta/services.json 如果此文件/文件夹不存在,请创建它并添加一些 json 以查看您是否可以在浏览器中访问它。如果禁止/拒绝,请参阅以下权限:
Check you have these folders
检查你有这些文件夹
app/storage/views
app/storage/logs
app/storage/sessions
Set everything to be read/write
将所有内容设置为读/写
chmod -R 777 /app/storage
Create services.json and add the following
创建 services.json 并添加以下内容
{
"providers": []
}
After creating the above try loading the project or php artisan serve
创建以上尝试加载项目或 php artisan serve 后