File tree Expand file tree Collapse file tree 1 file changed +27
-0
lines changed
Expand file tree Collapse file tree 1 file changed +27
-0
lines changed Original file line number Diff line number Diff line change @@ -8,3 +8,30 @@ title: DigitalOcean Spaces
88
99The DO Spaces api are compatible with those of S3, from Flysystem's perspective this means you can use the
1010` league/flysystem-aws-s3-v3 ` adapter.
11+
12+ ## Installation
13+
14+ ~~~ bash
15+ composer require league/flysystem-aws-s3-v3
16+ ~~~
17+
18+ ## Usage
19+
20+ ~~~ php
21+ use Aws\S3\S3Client;
22+ use League\Flysystem\AwsS3v3\AwsS3Adapter;
23+ use League\Flysystem\Filesystem;
24+
25+ $client = new S3Client([
26+ 'credentials' => [
27+ 'key' => 'your-key',
28+ 'secret' => 'your-secret',
29+ ],
30+ 'region' => 'your-region',
31+ 'version' => 'latest|version',
32+ 'endpoint' => 'https://your-region.digitaloceanspaces.com',
33+ ]);
34+
35+ $adapter = new AwsS3Adapter($client, 'your-bucket-name');
36+
37+ $filesystem = new Filesystem($adapter);
You can’t perform that action at this time.
0 commit comments