Skip to content

Commit

Permalink
Update docs for 2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
tgalopin committed Jan 17, 2021
1 parent daf3edc commit b00803d
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 22 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# flysystem-bundle

[![Build Status](https://travis-ci.org/thephpleague/flysystem-bundle.svg?branch=master)](https://travis-ci.org/thephpleague/flysystem-bundle)
[![Packagist Version](https://img.shields.io/packagist/v/league/flysystem-bundle.svg?style=flat-square)](https://packagist.org/packages/league/flysystem-bundle)
[![Software license](https://img.shields.io/github/license/thephpleague/flysystem-bundle.svg?style=flat-square)](https://github.com/thephpleague/flysystem-bundle/blob/master/LICENSE)

Expand All @@ -14,6 +13,7 @@ on the execution environment (local files in development, cloud storage in produ

> Note: you are reading the documentation for flysystem-bundle 2.0, which relies on Flysystem 2.X.
> If you use Flysystem 1.X, use [flysystem-bundle 1.X](https://github.com/thephpleague/flysystem-bundle/tree/1.x).
> Read the [Upgrade guide](https://github.com/thephpleague/flysystem-bundle/blob/master/UPGRADE.md) to learn how to upgrade.
## Installation

Expand Down
14 changes: 7 additions & 7 deletions UPGRADE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Upgrading from 1.0 to 2.0

flysystem-bundle 2.0 introduces Backward Compatibility breaks, meaning you will need to update
flysystem-bundle 2.0 introduces backward incompatible changes, meaning you will need to update
the code of your projects to upgrade.

flysystem-bundle 2.0 relies on Flysystem 2.0, which introduced most of the backward incompatible
Expand All @@ -9,9 +9,9 @@ changes. You should read

In addition to the library updates, the bundle also changed a bit:

* Following the drop of support for several Cloud providers in Flysystem itself, the bundle no longer
natively supports Azure, Dropbox, Rackspace and WebDAV. If the need arise for community adapters to be
ported to Flysystem 2 and flysystem-bundle 2, we could add them again.
* Following their removal from the main library, null, cache, zip and replicate adapters were removed
from the bundle as well.
* Following the drop of support for plugins in the main library, the bundle does not support them anymore.
* Add official support for PHP 8 ;
* Migration to AsyncAWS 1.0 ;
* Drop support for PHP 7.1 ;
* Drop support for Azure, Dropbox, Rackspace and WebDAV adapters (following the main library) ;
* Drop support for null, cache, zip and replicate adapters (following the main library) ;
* Drop support for plugins ;
64 changes: 52 additions & 12 deletions docs/2-cloud-storage-providers.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ including many cloud storage providers. This bundle provides the same level of s
cloud providers by providing corresponding adapters in the configuration.

* [AsyncAws S3](#asyncaws-s3)
* [AWS S3](#aws-s3)
* [AWS S3](#aws-sdk-s3)
* [DigitalOcean Spaces](#digitalocean-spaces)
* [Scaleway Object Storage](#scaleway-object-storage)
* [Google Cloud Storage](#google-cloud-storage)
Expand All @@ -15,7 +15,7 @@ cloud providers by providing corresponding adapters in the configuration.
### Installation

```
composer require async-aws/flysystem-s3
composer require league/flysystem-async-aws-s3
```

### Usage
Expand Down Expand Up @@ -57,16 +57,6 @@ flysystem:
prefix: 'optional/path/prefix'
```
## DigitalOcean Spaces
The DigitalOcean Spaces are compatible with the AWS S3 API, meaning that you can use the same configuration
as for a AWS storage.
## Scaleway Object Storage
The Scaleway Object Storage is compatible with the AWS S3 API, meaning that you can use the same configuration
as for a AWS storage.
## Google Cloud Storage
### Installation
Expand All @@ -90,6 +80,56 @@ flysystem:
prefix: 'optional/path/prefix'
```
## DigitalOcean Spaces
The DigitalOcean Spaces are compatible with the AWS S3 API, meaning that you can use the same configuration
as for a AWS storage. For example:
```yaml
# config/packages/flysystem.yaml

services:
digitalocean_spaces_client:
class: 'AsyncAws\S3\S3Client'
arguments:
- endpoint: '%env(DIGITALOCEAN_SPACES_ENDPOINT)%'
accessKeyId: '%env(DIGITALOCEAN_SPACES_ID)%'
accessKeySecret: '%env(DIGITALOCEAN_SPACES_SECRET)%'

flysystem:
storages:
cdn.storage:
adapter: 'asyncaws'
options:
client: 'digitalocean_spaces_client'
bucket: '%env(DIGITALOCEAN_SPACES_BUCKET)%'
```
## Scaleway Object Storage
The Scaleway Object Storage is compatible with the AWS S3 API, meaning that you can use the same configuration
as for a AWS storage. For example:
```yaml
# config/packages/flysystem.yaml

services:
scaleway_spaces_client:
class: 'AsyncAws\S3\S3Client'
arguments:
- endpoint: '%env(SCALEWAY_SPACES_ENDPOINT)%'
accessKeyId: '%env(SCALEWAY_SPACES_ID)%'
accessKeySecret: '%env(SCALEWAY_SPACES_SECRET)%'

flysystem:
storages:
cdn.storage:
adapter: 'asyncaws'
options:
client: 'scaleway_spaces_client'
bucket: '%env(SCALEWAY_SPACES_BUCKET)%'
```
## Next
[Interacting with FTP and SFTP servers](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/3-interacting-with-ftp-and-sftp-servers.md)
4 changes: 3 additions & 1 deletion docs/3-interacting-with-ftp-and-sftp-servers.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@ for other storages.

### Installation

The FTP adapter is shipped natively by Flysystem and does not need to be installed.
```
composer require league/flysystem-ftp
```

### Usage

Expand Down
2 changes: 1 addition & 1 deletion docs/5-creating-a-custom-adapter.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Creating a custom adapter

[Read the associated library documentation](https://flysystem.thephpleague.com/docs/advanced/creating-an-adapter/)
[Read the associated library documentation](https://flysystem.thephpleague.com/v2/docs/advanced/creating-an-adapter/)

If you have highly specific requirements, you may need to create your own
Flysystem adapter. To do so, you first need to create the adapter code itself
Expand Down

0 comments on commit b00803d

Please sign in to comment.