mirror of
https://github.com/minio/minio.git
synced 2025-11-13 15:21:36 -05:00
fs/bucket: Move bucket metadata into buckets.json
This commit is contained in:
@@ -59,12 +59,20 @@ func (s *MyAPIFSCacheSuite) SetUpSuite(c *C) {
|
||||
fsroot, err := ioutil.TempDir(os.TempDir(), "api-")
|
||||
c.Assert(err, IsNil)
|
||||
|
||||
fs.SetFSMultipartsConfigPath(filepath.Join(root, "multiparts.json"))
|
||||
fs.SetFSMultipartsConfigPath(filepath.Join(root, "multiparts-session.json"))
|
||||
fs.SetFSBucketsConfigPath(filepath.Join(root, "buckets.json"))
|
||||
multiparts := &fs.Multiparts{}
|
||||
multiparts.Version = "1"
|
||||
multiparts.ActiveSession = make(map[string]*fs.MultipartSession)
|
||||
perr := fs.SaveMultipartsSession(multiparts)
|
||||
c.Assert(perr, IsNil)
|
||||
|
||||
buckets := &fs.Buckets{}
|
||||
buckets.Version = "1"
|
||||
buckets.Metadata = make(map[string]*fs.BucketMetadata)
|
||||
perr = fs.SaveBucketsMetadata(buckets)
|
||||
c.Assert(perr, IsNil)
|
||||
|
||||
accessKeyID, perr := generateAccessKeyID()
|
||||
c.Assert(perr, IsNil)
|
||||
secretAccessKey, perr := generateSecretAccessKey()
|
||||
|
||||
Reference in New Issue
Block a user