xutl / flysystem-aliyun-oss
This is a Flysystem adapter for the Aliyun OSS.
1.0.2
2018-10-20 08:46 UTC
Requires
- aliyuncs/oss-sdk-php: ~2.3
- league/flysystem: ^1.0.8
This package is auto-updated.
Last update: 2024-12-20 22:50:54 UTC
README
This is a Flysystem adapter for the Aliyun OSS
Installation
composer require xutl/flysystem-aliyun-oss
for Laravel
This service provider must be registered.
// config/app.php 'providers' => [ '...', XuTL\Flysystem\AliyunOss\AliyunOssServiceProvider::class, ];
edit the config file: config/filesystems.php
add config
'oss' => [ 'driver' => 'oss', 'access_id' => env('OSS_ACCESS_ID','your id'), 'access_key' => env('OSS_ACCESS_KEY','your key'), 'bucket' => env('OSS_BUCKET','your bucket'), 'endpoint' => env('OSS_ENDPOINT','your endpoint'), 'prefix' => env('OSS_PREFIX', ''), // optional ],
change default to oss
'default' => 'oss'
Use
see Laravel wiki