inherit logging config from ocis.yaml, let extensions overwrite their logging. Considering using a package level global logging...
This commit is contained in:
@@ -7,7 +7,6 @@ import (
|
||||
"github.com/owncloud/ocis/ocis-pkg/log"
|
||||
"github.com/owncloud/ocis/ocis-pkg/version"
|
||||
"github.com/owncloud/ocis/storage/pkg/config"
|
||||
"github.com/owncloud/ocis/storage/pkg/flagset"
|
||||
"github.com/spf13/viper"
|
||||
"github.com/urfave/cli/v2"
|
||||
)
|
||||
@@ -27,7 +26,7 @@ func Execute(cfg *config.Config) error {
|
||||
},
|
||||
},
|
||||
|
||||
Flags: flagset.RootWithConfig(cfg),
|
||||
//Flags: flagset.RootWithConfig(cfg),
|
||||
|
||||
Before: func(c *cli.Context) error {
|
||||
logger := NewLogger(cfg)
|
||||
|
||||
@@ -31,7 +31,7 @@ func StorageMetadata(cfg *config.Config) *cli.Command {
|
||||
Name: "storage-metadata",
|
||||
Usage: "Start storage-metadata service",
|
||||
// TODO(refs) at this point it might make sense delegate log flags to each individual storage command.
|
||||
Flags: append(flagset.StorageMetadata(cfg), flagset.RootWithConfig(cfg)...),
|
||||
Flags: flagset.StorageMetadata(cfg),
|
||||
Category: "Extensions",
|
||||
Action: func(c *cli.Context) error {
|
||||
logger := NewLogger(cfg)
|
||||
|
||||
Reference in New Issue
Block a user