joolanders/flysystem-aws-s3-small

Flysystem 适配器,用于 S3 而不使用完整的 AWS SDK

1.0.0 2018-11-27 16:22 UTC

This package is not auto-updated.

Last update: 2024-09-26 20:20:15 UTC


README

这是一个无需庞大的 AWS PHP SDK 即可适配 s3 的 Flysystem 适配器

安装

composer require joolanders/flysystem-aws-s3-small

引导

<?php

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

$configuration = new \Akeeba\Engine\Postproc\Connector\S3v4\Configuration(
    'your-key',
    'your-secret',
    'V2|V4', // optional
    'your-region' // optional
);

$connector = new \Akeeba\Engine\Postproc\Connector\S3v4\Connector($configuration);
$adapter = new \Joolanders\Flysystem\S3Small\S3SmallAdapter($connector, 'your-bucket');
$filesystem = new \League\Flysystem\Filesystem($adapter);