mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-02-26 07:28:46 -06:00
sequential access to viper config (still broken) + add delayed execution to storage-sharing
This commit is contained in:
@@ -4,6 +4,8 @@ import (
|
||||
"os"
|
||||
"strings"
|
||||
|
||||
"github.com/owncloud/ocis/ocis-pkg/sync"
|
||||
|
||||
"github.com/micro/cli/v2"
|
||||
"github.com/owncloud/ocis/graph/pkg/config"
|
||||
"github.com/owncloud/ocis/graph/pkg/flagset"
|
||||
@@ -66,6 +68,8 @@ func NewLogger(cfg *config.Config) log.Logger {
|
||||
|
||||
// ParseConfig reads graph configuration from fs.
|
||||
func ParseConfig(c *cli.Context, cfg *config.Config) error {
|
||||
sync.ParsingViperConfig.Lock()
|
||||
defer sync.ParsingViperConfig.Unlock()
|
||||
logger := NewLogger(cfg)
|
||||
|
||||
viper.SetEnvKeyReplacer(strings.NewReplacer(".", "_"))
|
||||
|
||||
Reference in New Issue
Block a user