diff --git a/storage/pkg/command/drivers.go b/storage/pkg/command/drivers.go index 8d501e6aa0..6cc6eb1257 100644 --- a/storage/pkg/command/drivers.go +++ b/storage/pkg/command/drivers.go @@ -91,7 +91,7 @@ func drivers(cfg *config.Config) map[string]interface{} { "user_layout": cfg.Reva.Storages.Common.UserLayout, "treetime_accounting": true, "treesize_accounting": true, - "owner": "95cb8724-03b2-11eb-a0a6-c33ef8ef53ad", // the accounts service system account uuid + "owner": cfg.Reva.Storages.OCIS.ServiceUserUUID, // the accounts service system account uuid }, "s3": map[string]interface{}{ "region": cfg.Reva.Storages.S3.Region, diff --git a/storage/pkg/config/config.go b/storage/pkg/config/config.go index 506830ef75..98a95a243b 100644 --- a/storage/pkg/config/config.go +++ b/storage/pkg/config/config.go @@ -165,6 +165,7 @@ type StorageConfig struct { OwnCloud DriverOwnCloud S3 DriverS3 Common DriverCommon + OCIS DriverOCIS // TODO checksums ... figure out what that is supposed to do } @@ -242,6 +243,11 @@ type DriverEOS struct { GatewaySVC string } +// DriverOCIS defines the available oCIS storage driver configuration. +type DriverOCIS struct { + ServiceUserUUID string +} + // DriverOwnCloud defines the available ownCloud storage driver configuration. type DriverOwnCloud struct { DriverCommon diff --git a/storage/pkg/flagset/driverocis.go b/storage/pkg/flagset/driverocis.go index 76eb5e61b4..75f80caaae 100644 --- a/storage/pkg/flagset/driverocis.go +++ b/storage/pkg/flagset/driverocis.go @@ -30,5 +30,12 @@ func DriverOCISWithConfig(cfg *config.Config) []cli.Flag { EnvVars: []string{"STORAGE_DRIVER_OCIS_LAYOUT"}, Destination: &cfg.Reva.Storages.Common.UserLayout, }, + &cli.StringFlag{ + Name: "service-user-uuid", + Value: "95cb8724-03b2-11eb-a0a6-c33ef8ef53ad", + Usage: "uuid of the internal service user", + EnvVars: []string{"STORAGE_DRIVER_OCIS_SERVICE_USER_UUID"}, + Destination: &cfg.Reva.Storages.OCIS.ServiceUserUUID, + }, } }