mirror of
https://github.com/minio/minio.git
synced 2025-01-23 04:33:15 -05:00
nas gateway: fix regression in global bucket policy initialization (#6243)
Fixes #6238 globalPolicySys used to be initialized in fs/xl layer. The referenced commit moved this logic to server/gateway initialization,but a check to avoid double initialization prevented globalPolicySys to be loaded from disk for NAS. fixes regression from commit be1700f5950b5630ef3bfd81a0785f350559ebfe
This commit is contained in:
parent
a1a426e523
commit
5f69f04909
@ -217,12 +217,7 @@ func StartGateway(ctx *cli.Context, gw Gateway) {
|
||||
logger.FatalIf(err, "Unable to initialize gateway backend")
|
||||
}
|
||||
|
||||
if gw.Name() != "nas" {
|
||||
// Initialize policy sys for all gateways. NAS gateway already
|
||||
// initializes policy sys internally, avoid double initialization.
|
||||
// Additionally also don't block the initialization of gateway.
|
||||
go globalPolicySys.Init(newObject)
|
||||
}
|
||||
go globalPolicySys.Init(newObject)
|
||||
|
||||
// Once endpoints are finalized, initialize the new object api.
|
||||
globalObjLayerMutex.Lock()
|
||||
|
Loading…
x
Reference in New Issue
Block a user