mirror of
https://github.com/opencloud-eu/opencloud.git
synced 2026-07-19 12:04:09 -04:00
Make the storage-users propagator configurable
This commit is contained in:
@@ -94,6 +94,7 @@ type Drivers struct {
|
||||
// OCISDriver is the storage driver configuration when using 'ocis' storage driver
|
||||
type OCISDriver struct {
|
||||
MetadataBackend string `yaml:"metadata_backend" env:"OCIS_DECOMPOSEDFS_METADATA_BACKEND;STORAGE_USERS_OCIS_METADATA_BACKEND" desc:"The backend to use for storing metadata. Supported values are 'messagepack' and 'xattrs'. The setting 'messagepack' uses a dedicated file to store file metadata while 'xattrs' uses extended attributes to store file metadata. Defaults to 'messagepack'."`
|
||||
Propagator string `yaml:"propagator" env:"OCIS_DECOMPOSEDFS_PROPAGATOR;STORAGE_USERS_OCIS_PROPAGATOR" desc:"The propagator to use. Only 'sync' is fully supported at that point, 'async' is available as an experimental option."`
|
||||
// Root is the absolute path to the location of the data
|
||||
Root string `yaml:"root" env:"STORAGE_USERS_OCIS_ROOT" desc:"The directory where the filesystem storage will store blobs and metadata. If not defined, the root directory derives from $OCIS_BASE_DATA_PATH:/storage/users."`
|
||||
UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_OCIS_USER_LAYOUT" desc:"Template string for the user storage layout in the user directory."`
|
||||
@@ -116,6 +117,7 @@ type OCISDriver struct {
|
||||
// S3NGDriver is the storage driver configuration when using 's3ng' storage driver
|
||||
type S3NGDriver struct {
|
||||
MetadataBackend string `yaml:"metadata_backend" env:"STORAGE_USERS_S3NG_METADATA_BACKEND" desc:"The backend to use for storing metadata. Supported values are 'xattrs' and 'messagepack'. The setting 'xattrs' uses extended attributes to store file metadata while 'messagepack' uses a dedicated file to store file metadata. Defaults to 'xattrs'."`
|
||||
Propagator string `yaml:"propagator" env:"OCIS_DECOMPOSEDFS_PROPAGATOR;STORAGE_USERS_S3NG_PROPAGATOR" desc:"The propagator to use. Only 'sync' is fully supported at that point, 'async' is available as an experimental option."`
|
||||
// Root is the absolute path to the location of the data
|
||||
Root string `yaml:"root" env:"STORAGE_USERS_S3NG_ROOT" desc:"The directory where the filesystem storage will store metadata for blobs. If not defined, the root directory derives from $OCIS_BASE_DATA_PATH:/storage/users."`
|
||||
UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_S3NG_USER_LAYOUT" desc:"Template string for the user storage layout in the user directory."`
|
||||
|
||||
@@ -116,6 +116,7 @@ func OwnCloudSQL(cfg *config.Config) map[string]interface{} {
|
||||
func Ocis(cfg *config.Config) map[string]interface{} {
|
||||
return map[string]interface{}{
|
||||
"metadata_backend": cfg.Drivers.OCIS.MetadataBackend,
|
||||
"propagator": cfg.Drivers.OCIS.Propagator,
|
||||
"root": cfg.Drivers.OCIS.Root,
|
||||
"user_layout": cfg.Drivers.OCIS.UserLayout,
|
||||
"share_folder": cfg.Drivers.OCIS.ShareFolder,
|
||||
@@ -171,6 +172,7 @@ func Ocis(cfg *config.Config) map[string]interface{} {
|
||||
func OcisNoEvents(cfg *config.Config) map[string]interface{} {
|
||||
return map[string]interface{}{
|
||||
"metadata_backend": cfg.Drivers.OCIS.MetadataBackend,
|
||||
"propagator": cfg.Drivers.OCIS.Propagator,
|
||||
"root": cfg.Drivers.OCIS.Root,
|
||||
"user_layout": cfg.Drivers.OCIS.UserLayout,
|
||||
"share_folder": cfg.Drivers.OCIS.ShareFolder,
|
||||
@@ -225,6 +227,7 @@ func S3(cfg *config.Config) map[string]interface{} {
|
||||
func S3NG(cfg *config.Config) map[string]interface{} {
|
||||
return map[string]interface{}{
|
||||
"metadata_backend": cfg.Drivers.S3NG.MetadataBackend,
|
||||
"propagator": cfg.Drivers.S3NG.Propagator,
|
||||
"root": cfg.Drivers.S3NG.Root,
|
||||
"user_layout": cfg.Drivers.S3NG.UserLayout,
|
||||
"share_folder": cfg.Drivers.S3NG.ShareFolder,
|
||||
@@ -284,6 +287,7 @@ func S3NG(cfg *config.Config) map[string]interface{} {
|
||||
func S3NGNoEvents(cfg *config.Config) map[string]interface{} {
|
||||
return map[string]interface{}{
|
||||
"metadata_backend": cfg.Drivers.S3NG.MetadataBackend,
|
||||
"propagator": cfg.Drivers.S3NG.Propagator,
|
||||
"root": cfg.Drivers.S3NG.Root,
|
||||
"user_layout": cfg.Drivers.S3NG.UserLayout,
|
||||
"share_folder": cfg.Drivers.S3NG.ShareFolder,
|
||||
|
||||
Reference in New Issue
Block a user