filesystem.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. <?php
  2. return [
  3. // 默认磁盘
  4. 'default' => env('filesystem.driver', 'local'),
  5. // 磁盘列表
  6. 'disks' => [
  7. 'local' => [
  8. 'type' => 'local',
  9. 'root' => app()->getRuntimePath() . 'storage',
  10. ],
  11. 'public' => [
  12. // 磁盘类型
  13. 'type' => 'local',
  14. // 磁盘路径
  15. 'root' => app()->getRootPath() . 'public/storage',
  16. // 磁盘路径对应的外部URL路径
  17. 'url' => '/storage',
  18. // 可见性
  19. 'visibility' => 'public',
  20. ],
  21. // 更多的磁盘配置信息
  22. 'resource' => [
  23. // 磁盘类型
  24. 'type' => 'local',
  25. // 磁盘路径
  26. 'root' => app()->getRootPath() . 'public/resource',
  27. // 磁盘路径对应的外部URL路径
  28. 'url' => '/resource',
  29. // 可见性
  30. 'visibility' => 'public',
  31. ],
  32. ],
  33. "image"=>[
  34. "path"=>["avatar","video","image","circle","advert","goods","activity","icon","wximg"],
  35. "ext"=>["png","jpeg","gif","jpg"],
  36. "size"=>2//M
  37. ],
  38. "video"=>[
  39. "path"=>["video"],
  40. "ext" =>["mp4","megp4"]
  41. ],
  42. ];