Add fs prefix (directory)

This ensures the fs root is clean and does not mess with
the metadata. Also in the future this will allow for multiple
filesystems to be created in one bucket.
This commit is contained in:
Cyrill Troxler 2018-07-27 21:37:32 +02:00
parent e995487c45
commit 2341274393
6 changed files with 31 additions and 8 deletions

View file

@ -49,7 +49,9 @@ func newS3qlMounter(b *bucket, cfg *Config) (Mounter, error) {
ssl: ssl,
}
url.Path = path.Join(url.Path, b.Name)
// s3ql requires a trailing slash or it will just
// prepend the fspath to the s3ql files
url.Path = path.Join(url.Path, b.Name, b.FSPath) + "/"
s3ql.bucketURL = url.String()
if !ssl {