Driver [oss] is not supported. {“exception“:“[object] (InvalidArgumentException(code: 0)

最近在Laravel环境下,使用阿里云的oss上传图片,报如下错误:

 Driver [oss] is not supported. {"exception":"[object] (InvalidArgumentException(code: 0):
  Driver [oss] is not supported. at 
/home/wwwroot/XXXX/vendor/laravel/framework/src/Illuminate/Filesystem/FilesystemManager.php:126)


在网上找了N多解决办法,都没解决问题。后来把整个代码框架都研究了一番,发现,需要安装依赖包:

composer require  "jacobcyl/ali-oss-storage: dev-master"


后,再重新上传,就能上传成功了!

Sea Bridge

古之立大志者,不惟有超世之才 亦必有坚韧不拔之志!

发表评论