From 9f549f848da07b38979b95a6b2eb8ead392eda98 Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Thu, 8 Aug 2019 16:49:34 +0100 Subject: [PATCH] fs: add feature flag BucketBasedRootOK #3421 This is for bucket based remotes which can be used from the root. Eventually all bucket based remotes will support this. --- fs/fs.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/fs/fs.go b/fs/fs.go index 2dbeb1e11..1138f33cf 100644 --- a/fs/fs.go +++ b/fs/fs.go @@ -470,6 +470,7 @@ type Features struct { WriteMimeType bool // can set the mime type of objects CanHaveEmptyDirectories bool // can have empty directories BucketBased bool // is bucket based (like s3, swift etc) + BucketBasedRootOK bool // is bucket based and can use from root SetTier bool // allows set tier functionality on objects GetTier bool // allows to retrieve storage tier of objects ServerSideAcrossConfigs bool // can server side copy between different remotes of the same type @@ -734,6 +735,7 @@ func (ft *Features) Mask(f Fs) *Features { ft.WriteMimeType = ft.WriteMimeType && mask.WriteMimeType ft.CanHaveEmptyDirectories = ft.CanHaveEmptyDirectories && mask.CanHaveEmptyDirectories ft.BucketBased = ft.BucketBased && mask.BucketBased + ft.BucketBasedRootOK = ft.BucketBasedRootOK && mask.BucketBasedRootOK ft.SetTier = ft.SetTier && mask.SetTier ft.GetTier = ft.GetTier && mask.GetTier