mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-05-24 16:41:35 -04:00
Merge branch 'master' into feature/public-shares
This commit is contained in:
40
pkg/command/accounts.go
Normal file
40
pkg/command/accounts.go
Normal file
@@ -0,0 +1,40 @@
|
||||
package command
|
||||
|
||||
import (
|
||||
"github.com/micro/cli/v2"
|
||||
"github.com/owncloud/ocis-accounts/pkg/command"
|
||||
svcconfig "github.com/owncloud/ocis-accounts/pkg/config"
|
||||
"github.com/owncloud/ocis-accounts/pkg/flagset"
|
||||
"github.com/owncloud/ocis/pkg/config"
|
||||
"github.com/owncloud/ocis/pkg/register"
|
||||
)
|
||||
|
||||
// AccountsCommand is the entrypoint for the accounts command.
|
||||
func AccountsCommand(cfg *config.Config) *cli.Command {
|
||||
return &cli.Command{
|
||||
Name: "accounts",
|
||||
Usage: "Start accounts server",
|
||||
Category: "Extensions",
|
||||
Flags: flagset.ServerWithConfig(cfg.Accounts),
|
||||
Action: func(c *cli.Context) error {
|
||||
accountsCommand := command.Server(configureAccounts(cfg))
|
||||
if err := accountsCommand.Before(c); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return cli.HandleAction(accountsCommand.Action, c)
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
func configureAccounts(cfg *config.Config) *svcconfig.Config {
|
||||
cfg.Accounts.Log.Level = cfg.Log.Level
|
||||
cfg.Accounts.Log.Pretty = cfg.Log.Pretty
|
||||
cfg.Accounts.Log.Color = cfg.Log.Color
|
||||
|
||||
return cfg.Accounts
|
||||
}
|
||||
|
||||
func init() {
|
||||
register.AddCommand(AccountsCommand)
|
||||
}
|
||||
28
pkg/command/migration-import.go
Normal file
28
pkg/command/migration-import.go
Normal file
@@ -0,0 +1,28 @@
|
||||
package command
|
||||
|
||||
import (
|
||||
"github.com/micro/cli/v2"
|
||||
"github.com/owncloud/ocis-migration/pkg/command"
|
||||
toolconfig "github.com/owncloud/ocis-migration/pkg/config"
|
||||
"github.com/owncloud/ocis-migration/pkg/flagset"
|
||||
"github.com/owncloud/ocis/pkg/config"
|
||||
"github.com/owncloud/ocis/pkg/register"
|
||||
)
|
||||
|
||||
// ImportCommand is the entrypoint for the accounts command.
|
||||
func ImportCommand(cfg *config.Config) *cli.Command {
|
||||
tc := toolconfig.New()
|
||||
return &cli.Command{
|
||||
Name: "import",
|
||||
Usage: "Import a user exported by owncloud/data_exporter",
|
||||
Flags: flagset.ImportWithConfig(tc),
|
||||
Action: func(c *cli.Context) error {
|
||||
importCommand := command.Import(tc)
|
||||
return cli.HandleAction(importCommand.Action, c)
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
func init() {
|
||||
register.AddCommand(ImportCommand)
|
||||
}
|
||||
40
pkg/command/revastorageeos.go
Normal file
40
pkg/command/revastorageeos.go
Normal file
@@ -0,0 +1,40 @@
|
||||
package command
|
||||
|
||||
import (
|
||||
"github.com/micro/cli/v2"
|
||||
"github.com/owncloud/ocis-reva/pkg/command"
|
||||
svcconfig "github.com/owncloud/ocis-reva/pkg/config"
|
||||
"github.com/owncloud/ocis-reva/pkg/flagset"
|
||||
"github.com/owncloud/ocis/pkg/config"
|
||||
"github.com/owncloud/ocis/pkg/register"
|
||||
)
|
||||
|
||||
// RevaStorageEOSCommand is the entrypoint for the reva-storage-oc command.
|
||||
func RevaStorageEOSCommand(cfg *config.Config) *cli.Command {
|
||||
return &cli.Command{
|
||||
Name: "reva-storage-eos",
|
||||
Usage: "Start reva eos storage",
|
||||
Category: "Extensions",
|
||||
Flags: flagset.StorageEOSWithConfig(cfg.Reva),
|
||||
Action: func(c *cli.Context) error {
|
||||
scfg := configureRevaStorageEOS(cfg)
|
||||
|
||||
return cli.HandleAction(
|
||||
command.StorageEOS(scfg).Action,
|
||||
c,
|
||||
)
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
func configureRevaStorageEOS(cfg *config.Config) *svcconfig.Config {
|
||||
cfg.Reva.Log.Level = cfg.Log.Level
|
||||
cfg.Reva.Log.Pretty = cfg.Log.Pretty
|
||||
cfg.Reva.Log.Color = cfg.Log.Color
|
||||
|
||||
return cfg.Reva
|
||||
}
|
||||
|
||||
func init() {
|
||||
register.AddCommand(RevaStorageEOSCommand)
|
||||
}
|
||||
40
pkg/command/revastorageeosdata.go
Normal file
40
pkg/command/revastorageeosdata.go
Normal file
@@ -0,0 +1,40 @@
|
||||
package command
|
||||
|
||||
import (
|
||||
"github.com/micro/cli/v2"
|
||||
"github.com/owncloud/ocis-reva/pkg/command"
|
||||
svcconfig "github.com/owncloud/ocis-reva/pkg/config"
|
||||
"github.com/owncloud/ocis-reva/pkg/flagset"
|
||||
"github.com/owncloud/ocis/pkg/config"
|
||||
"github.com/owncloud/ocis/pkg/register"
|
||||
)
|
||||
|
||||
// RevaStorageEOSDataCommand is the entrypoint for the reva-storage-eos-data command.
|
||||
func RevaStorageEOSDataCommand(cfg *config.Config) *cli.Command {
|
||||
return &cli.Command{
|
||||
Name: "reva-storage-eos-data",
|
||||
Usage: "Start reva eos storage dataprovider",
|
||||
Category: "Extensions",
|
||||
Flags: flagset.StorageEOSDataWithConfig(cfg.Reva),
|
||||
Action: func(c *cli.Context) error {
|
||||
scfg := configureRevaStorageEOSData(cfg)
|
||||
|
||||
return cli.HandleAction(
|
||||
command.StorageEOSData(scfg).Action,
|
||||
c,
|
||||
)
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
func configureRevaStorageEOSData(cfg *config.Config) *svcconfig.Config {
|
||||
cfg.Reva.Log.Level = cfg.Log.Level
|
||||
cfg.Reva.Log.Pretty = cfg.Log.Pretty
|
||||
cfg.Reva.Log.Color = cfg.Log.Color
|
||||
|
||||
return cfg.Reva
|
||||
}
|
||||
|
||||
func init() {
|
||||
register.AddCommand(RevaStorageEOSDataCommand)
|
||||
}
|
||||
@@ -32,8 +32,6 @@ func configureRevaStorageHome(cfg *config.Config) *svcconfig.Config {
|
||||
cfg.Reva.Log.Pretty = cfg.Log.Pretty
|
||||
cfg.Reva.Log.Color = cfg.Log.Color
|
||||
|
||||
cfg.Reva.Reva.StorageHome.ExposeDataServer = true
|
||||
|
||||
return cfg.Reva
|
||||
}
|
||||
|
||||
|
||||
@@ -32,8 +32,6 @@ func configureRevaStorageOC(cfg *config.Config) *svcconfig.Config {
|
||||
cfg.Reva.Log.Pretty = cfg.Log.Pretty
|
||||
cfg.Reva.Log.Color = cfg.Log.Color
|
||||
|
||||
cfg.Reva.Reva.StorageOC.ExposeDataServer = true
|
||||
|
||||
return cfg.Reva
|
||||
}
|
||||
|
||||
|
||||
@@ -15,15 +15,12 @@ import (
|
||||
)
|
||||
|
||||
var (
|
||||
// SimpleRuntimeServices declares which services will be started for the fullstack server
|
||||
// SimpleRuntimeServices declares which services will be started for the simple server
|
||||
SimpleRuntimeServices = []string{
|
||||
"hello",
|
||||
"phoenix",
|
||||
"reva-frontend",
|
||||
"reva-gateway",
|
||||
"reva-users",
|
||||
"reva-auth-basic",
|
||||
"reva-auth-bearer",
|
||||
"konnectd",
|
||||
"glauth",
|
||||
}
|
||||
)
|
||||
|
||||
@@ -50,7 +47,7 @@ func Simple(cfg *config.Config) *cli.Command {
|
||||
|
||||
runtime := runtime.New(
|
||||
runtime.Logger(logger),
|
||||
runtime.Services(append(runtime.RuntimeServices, SimpleRuntimeServices...)),
|
||||
runtime.Services(append(runtime.MicroServices, SimpleRuntimeServices...)),
|
||||
runtime.MicroRuntime(cmd.DefaultCmd.Options().Runtime),
|
||||
runtime.Context(c),
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user