filesystems.php 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?php
  2. return [
  3. /*
  4. |--------------------------------------------------------------------------
  5. | Default Filesystem Disk
  6. |--------------------------------------------------------------------------
  7. |
  8. | Here you may specify the default filesystem disk that should be used
  9. | by the framework. The "local" disk, as well as a variety of cloud
  10. | based disks are available to your application. Just store away!
  11. |
  12. */
  13. 'default' => env('FILESYSTEM_DRIVER', 'local'),
  14. // 'default' => 'qiniu',
  15. /*
  16. |--------------------------------------------------------------------------
  17. | Default Cloud Filesystem Disk
  18. |--------------------------------------------------------------------------
  19. |
  20. | Many applications store files both locally and in the cloud. For this
  21. | reason, you may specify a default "cloud" driver here. This driver
  22. | will be bound as the Cloud disk implementation in the container.
  23. |
  24. */
  25. 'cloud' => env('FILESYSTEM_CLOUD', 's3'),
  26. /*
  27. |--------------------------------------------------------------------------
  28. | Filesystem Disks
  29. |--------------------------------------------------------------------------
  30. |
  31. | Here you may configure as many filesystem "disks" as you wish, and you
  32. | may even configure multiple disks of the same driver. Defaults have
  33. | been setup for each driver as an example of the required options.
  34. |
  35. | Supported Drivers: "local", "ftp", "s3", "rackspace"
  36. |
  37. */
  38. 'disks' => [
  39. 'local' => [
  40. 'driver' => 'local',
  41. 'root' => storage_path('app'),
  42. 'url' => env('APP_URL') . '/storage',
  43. ],
  44. 'public' => [
  45. 'driver' => 'local',
  46. 'root' => storage_path('app/public'),
  47. 'url' => env('APP_URL') . '/storage',
  48. 'visibility' => 'public',
  49. ],
  50. 's3' => [
  51. 'driver' => 's3',
  52. 'key' => env('AWS_ACCESS_KEY_ID'),
  53. 'secret' => env('AWS_SECRET_ACCESS_KEY'),
  54. 'region' => env('AWS_DEFAULT_REGION'),
  55. 'bucket' => env('AWS_BUCKET'),
  56. ],
  57. 'qiniu' => [
  58. 'driver' => 'qiniu',
  59. 'access_key' => env('QINIU_ACCESS_KEY', 'CzcnCgVyMxMurMe9-KCCBWJrgqX27dObP68I6TB6'),
  60. 'secret_key' => env('QINIU_SECRET_KEY', '0SciZj9iZ_8bWpnBOMj-yG8qEe4lnVw0TPOXcngP'),
  61. 'bucket' => env('QINIU_BUCKET', 'tianzhihua'),
  62. 'domain' => env('QINIU_DOMAIN', 'resource.course.tianzhihua.cn'), // or host: https://xxxx.clouddn.com
  63. 'url' => 'http://resource.course.tianzhihua.cn/',
  64. ],
  65. ],
  66. ];