Merge pull request #704 from vadimeremeev/patch-1

Update README.md with details about .passwd-s3fs
This commit is contained in:
Takeshi Nakatani 2018-02-28 22:22:01 +09:00 committed by GitHub
commit e559f05326
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,24 +57,29 @@ $ brew install s3fs
Examples
--------
Enter your S3 identity and credential in a file `/path/to/passwd` and set
The default location for the s3fs password file can be created:
* using a .passwd-s3fs file in the users home directory (i.e. ~/.passwd-s3fs)
* using the system-wide /etc/passwd-s3fs file
Enter your S3 identity and credential in a file `~/.passwd-s3fs` and set
owner-only permissions:
```
echo MYIDENTITY:MYCREDENTIAL > /path/to/passwd
chmod 600 /path/to/passwd
echo MYIDENTITY:MYCREDENTIAL > ~/.passwd-s3fs
chmod 600 ~/.passwd-s3fs
```
Run s3fs with an existing bucket `mybucket` and directory `/path/to/mountpoint`:
```
s3fs mybucket /path/to/mountpoint -o passwd_file=/path/to/passwd
s3fs mybucket /path/to/mountpoint -o passwd_file=~/.passwd-s3fs
```
If you encounter any errors, enable debug output:
```
s3fs mybucket /path/to/mountpoint -o passwd_file=/path/to/passwd -o dbglevel=info -f -o curldbg
s3fs mybucket /path/to/mountpoint -o passwd_file=~/.passwd-s3fs -o dbglevel=info -f -o curldbg
```
You can also mount on boot by entering the following line to `/etc/fstab`:
@ -92,7 +97,7 @@ mybucket /path/to/mountpoint fuse.s3fs _netdev,allow_other 0 0
If you use s3fs with a non-Amazon S3 implementation, specify the URL and path-style requests:
```
s3fs mybucket /path/to/mountpoint -o passwd_file=/path/to/passwd -o url=http://url.to.s3/ -o use_path_request_style
s3fs mybucket /path/to/mountpoint -o passwd_file=~/.passwd-s3fs -o url=http://url.to.s3/ -o use_path_request_style
```
or(fstab)