huiwang/flysystem-oss

flysystem adapter for the aliyun oss storage

Maintainers

Package info

github.com/huiwanggo/flysystem-oss

pkg:composer/huiwang/flysystem-oss

Statistics

Installs: 9

Dependents: 0

Suggesters: 0

Stars: 5

Open Issues: 0

1.0.1 2020-05-18 13:13 UTC

This package is auto-updated.

Last update: 2026-03-01 00:31:34 UTC


README

💾 Flysystem adapter for the aliyun oss storage

安装

composer require "huiwang/flysystem-oss" -vvv

使用

$accessKeyId = '';
$accessKeySecret = '';
$endpoint = '';
$bucket = '';

$client = new \OSS\OssClient($accessKeyId, $accessKeySecret, $endpoint);

$adapter = new \Huiwang\Flysystem\Oss\OssAdapter($client, $bucket);

$filesystem = new \League\Flysystem\Filesystem($adapter, ['disable_asserts' => true]);

$filesystem->addPlugin(new \Huiwang\Flysystem\Oss\Plugins\FileUrl());
$filesystem->addPlugin(new \Huiwang\Flysystem\Oss\Plugins\TemporaryUrl());

API

API - Flysystem