Skip to content

Commit c8c94c8

Browse files
committed
Work on documentation
1 parent 4fb6607 commit c8c94c8

5 files changed

Lines changed: 179 additions & 4 deletions

README.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,17 @@ composer require league/flysystem-bundle
2727
## Documentation
2828

2929
1. [Getting started](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/1-getting-started.md)
30-
2. [Caching](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-caching.md)
31-
3. [Using the mount manager](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/3-using-mount-manager.md)
32-
4. [Configuration reference](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/4-configuration-reference.md)
30+
2. Cloud storage providers:
31+
[Azure](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#azure),
32+
[AWS S3](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#aws),
33+
[DigitalOcean Spaces](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#digitalocean-spaces),
34+
[Scaleway Object Storage](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#scaleway-object-storage),
35+
[Google Cloud Storage](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#google-cloud-storage),
36+
[Rackspace](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#rackspace),
37+
[WebDAV](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/2-cloud-storage-providers.md#webdav)
38+
3. [Interacting with FTP and SFTP servers](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/3-interacting-with-ftp-and-sftp-servers.md)
39+
4. [Caching metadata in Symfony cache](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/4-caching-metadata-in-symfony-cache.md)
40+
5. [Configuration reference](https://github.com/thephpleague/flysystem-bundle/blob/master/docs/5-configuration-reference.md)
3341

3442
## Security Issues
3543

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
# Interacting with FTP and SFTP servers
2+
3+
Flysystem is able to interact using the same FilesystemInterface with FTP and SFTP servers.
4+
To configure this bundle for this usage, you can rely on adapters in the same way you would
5+
for other storages.
6+
7+
## FTP
8+
9+
### Installation
10+
11+
The FTP adapter is shipped natively by Flysystem and does not need to be installed.
12+
13+
### Usage
14+
15+
```yaml
16+
# config/packages/flysystem.yaml
17+
18+
flysystem:
19+
storages:
20+
backup.storage:
21+
adapter: 'ftp'
22+
options:
23+
host: 'ftp.example.com'
24+
username: 'username'
25+
password: 'password'
26+
port: 21
27+
root: '/path/to/root'
28+
passive: true
29+
ssl: true
30+
timeout: 30
31+
```
32+
33+
## SFTP
34+
35+
### Installation
36+
37+
```
38+
composer require league/flysystem-sftp
39+
```
40+
41+
### Usage
42+
43+
```yaml
44+
# config/packages/flysystem.yaml
45+
46+
flysystem:
47+
storages:
48+
backup.storage:
49+
adapter: 'sftp'
50+
options:
51+
host: 'example.com'
52+
port: 22
53+
username: 'username'
54+
password: 'password'
55+
private_key: 'path/to/or/contents/of/privatekey'
56+
root: '/path/to/root'
57+
timeout: 10
58+
```
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Caching metadata in Symfony cache

docs/4-configuration-reference.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

docs/5-configuration-reference.md

Lines changed: 109 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,109 @@
1+
# Configuration reference
2+
3+
```yaml
4+
flysystem:
5+
storages:
6+
users1.storage:
7+
adapter: 'aws'
8+
options:
9+
client: 'aws_client_service'
10+
bucket: 'bucket_name'
11+
prefix: 'optional/path/prefix'
12+
13+
users2.storage:
14+
adapter: 'azure'
15+
options:
16+
client: 'azure_client_service'
17+
container: 'container_name'
18+
prefix: 'optional/path/prefix'
19+
20+
users3.storage:
21+
adapter: 'cache'
22+
options:
23+
store: 'cache.app'
24+
source: 'fs_local'
25+
26+
users4.storage:
27+
adapter: 'custom_adapter'
28+
29+
users5.storage:
30+
adapter: 'dropbox'
31+
options:
32+
client: 'dropbox_client_service'
33+
prefix: 'optional/path/prefix'
34+
35+
users6.storage:
36+
adapter: 'ftp'
37+
options:
38+
host: 'ftp.example.com'
39+
username: 'username'
40+
password: 'password'
41+
port: 21
42+
root: '/path/to/root'
43+
passive: true
44+
ssl: true
45+
timeout: 30
46+
47+
users7.storage:
48+
adapter: 'gcloud'
49+
options:
50+
client: 'gcloud_client_service'
51+
bucket: 'bucket_name'
52+
prefix: 'optional/path/prefix'
53+
api_url: 'https://storage.googleapis.com'
54+
55+
users8.storage:
56+
adapter: 'local'
57+
options:
58+
directory: '%kernel.project_dir%/storage'
59+
lock: 0
60+
skip_links: false
61+
permissions:
62+
file:
63+
public: 0744
64+
private: 0700
65+
dir:
66+
public: 0755
67+
private: 0700
68+
69+
users9.storage:
70+
adapter: 'memory'
71+
72+
users10.storage:
73+
adapter: 'null'
74+
75+
users11.storage:
76+
adapter: 'rackspace'
77+
options:
78+
container: 'rackspace_container_service'
79+
prefix: 'optional/path/prefix'
80+
81+
users12.storage:
82+
adapter: 'replicate'
83+
options:
84+
source: 'fs_aws'
85+
replica: 'fs_local'
86+
87+
users13.storage:
88+
adapter: 'sftp'
89+
options:
90+
host: 'example.com'
91+
port: 22
92+
username: 'username'
93+
password: 'password'
94+
private_key: 'path/to/or/contents/of/privatekey'
95+
root: '/path/to/root'
96+
timeout: 10
97+
98+
users14.storage:
99+
adapter: 'webdav'
100+
options:
101+
client: 'webdav_client_service'
102+
prefix: 'optional/path/prefix'
103+
use_stream_copy: false
104+
105+
users15.storage:
106+
adapter: 'zip'
107+
options:
108+
path: '%kernel.project_dir%/archive.zip'
109+
```

0 commit comments

Comments
 (0)