mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-01-04 11:19:39 -06:00
21 lines
612 B
Go
21 lines
612 B
Go
package flagset
|
|
|
|
import (
|
|
"github.com/micro/cli/v2"
|
|
"github.com/owncloud/ocis/ocis-pkg/flags"
|
|
"github.com/owncloud/ocis/storage/pkg/config"
|
|
)
|
|
|
|
// DriverLocalWithConfig applies cfg to the root flagset
|
|
func DriverLocalWithConfig(cfg *config.Config) []cli.Flag {
|
|
return []cli.Flag{
|
|
&cli.StringFlag{
|
|
Name: "storage-local-root",
|
|
Value: flags.OverrideDefaultString(cfg.Reva.Storages.Local.Root, "/var/tmp/ocis/storage/local"),
|
|
Usage: "the path to the local storage root",
|
|
EnvVars: []string{"STORAGE_DRIVER_LOCAL_ROOT"},
|
|
Destination: &cfg.Reva.Storages.Local.Root,
|
|
},
|
|
}
|
|
}
|