jimchen/flysystem-aliyun-oss

Flysystem adapter for the Aliyun Oss SDK v2.*

v1.0.1 2018-08-27 02:51 UTC

This package is auto-updated.

Last update: 2024-11-18 03:03:06 UTC


README

Author Build Status Coverage Status Quality Score Software License Packagist Version

This is a Flysystem adapter for the Aliyun Oss SDK v2.*

Requirement

  • PHP >= 5.5.9
  • Composer
  • Openssl Extension
  • cURL Extension

Installing

$ composer require jimchen/flysystem-aliyun-oss -vvv

Usage

<?php
use OSS\OssClient;
use League\Flysystem\Filesystem;
use JimChen\Flysystem\AliyunOss\AliyunOssAdapter;

include __DIR__ . '/vendor/autoload.php';

$client = new OssClient([
    'your-access-key-id',
    'your-access-key-secret',
    'your-bucket-name',
    'your-endpoint'
]);

$adapter = new AliyunOssAdapter($client, 'your-bucket-name');
$filesystem = new Filesystem($adapter);

License

MIT