diff --git a/changelog/unreleased/fix-remove-unused-config-options.md b/changelog/unreleased/fix-remove-unused-config-options.md new file mode 100644 index 0000000000..f24eec9f34 --- /dev/null +++ b/changelog/unreleased/fix-remove-unused-config-options.md @@ -0,0 +1,12 @@ +Bugfix: Remove unused configuration options + +We've removed multiple unused configuration options: + +- `STORAGE_SYSTEM_DATAPROVIDER_INSECURE`, see also cs3org/reva#2993 +- `STORAGE_USERS_DATAPROVIDER_INSECURE`, see also cs3org/reva#2993 +- `STORAGE_SYSTEM_TEMP_FOLDER`, see also cs3org/reva#2993 +- `STORAGE_USERS_TEMP_FOLDER`, see also cs3org/reva#2993 +- `WEB_UI_CONFIG_VERSION`, see also owncloud/web#7130 +- `GATEWAY_COMMIT_SHARE_TO_STORAGE_REF`, see also cs3org/reva#3017 + +https://github.com/owncloud/ocis/pull/3973 diff --git a/docs/services/graph-explorer/_index.md b/docs/services/graph-explorer/_index.md index 917b059f1a..f395da2dfd 100644 --- a/docs/services/graph-explorer/_index.md +++ b/docs/services/graph-explorer/_index.md @@ -8,4 +8,11 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + + This service embeds [Graph-Explorer](https://github.com/owncloud/ocis/tree/master/graph-explorer) to provide a UI for ownCloud Infinite Scale. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/graph/_index.md b/docs/services/graph/_index.md index 8344431b3d..88419d3941 100644 --- a/docs/services/graph/_index.md +++ b/docs/services/graph/_index.md @@ -8,6 +8,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + This service provides a simple graph world API which can be used by clients or other extensions. +## Table of Contents + {{< toc-tree >}} diff --git a/docs/services/idp/_index.md b/docs/services/idp/_index.md index 5fc69e8552..47b62d22f8 100644 --- a/docs/services/idp/_index.md +++ b/docs/services/idp/_index.md @@ -7,4 +7,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + This service provides an OpenID Connect provider which is the default way to authenticate in oCIS. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/ocdav/_index.md b/docs/services/ocdav/_index.md index 24f9202bed..a675ccf84c 100644 --- a/docs/services/ocdav/_index.md +++ b/docs/services/ocdav/_index.md @@ -9,6 +9,7 @@ geekdocCollapseSection: true --- ## Abstract +This service provides the WebDAV API which is required by ownCloud clients. Previews (thumbnails) are provided by the [WebDAV service]({{ ../../webdav }}). ## Table of Contents diff --git a/docs/services/ocs/_index.md b/docs/services/ocs/_index.md index 609a362d64..3a3df3f464 100644 --- a/docs/services/ocs/_index.md +++ b/docs/services/ocs/_index.md @@ -8,4 +8,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + This service provides the OCS API which is required by some ownCloud clients. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/proxy/_index.md b/docs/services/proxy/_index.md index cad3836ad1..e4fbce6b97 100644 --- a/docs/services/proxy/_index.md +++ b/docs/services/proxy/_index.md @@ -7,4 +7,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- -This service provides a proxy service that routes requests to the correct extensions. +## Abstract + +The proxy service acts as an API Gateway and routes requests to the correct target service. It also provides standard proxy services. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/search/_index.md b/docs/services/search/_index.md index 01768a8326..ac340e6406 100644 --- a/docs/services/search/_index.md +++ b/docs/services/search/_index.md @@ -7,4 +7,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + This service provides search functionality. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/settings/_index.md b/docs/services/settings/_index.md index a08d972c0a..2b98862e01 100644 --- a/docs/services/settings/_index.md +++ b/docs/services/settings/_index.md @@ -45,3 +45,7 @@ The forms are generated from the registered *settings bundles*. if it's available. The SDK uses sensible defaults when ocis-settings is not part of the setup. For compatibility with ownCloud 10, a migration of ownCloud 10 settings into the storage of ocis-settings will be available. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/sharing/_index.md b/docs/services/sharing/_index.md index 86eb1fed2f..be41c1be9e 100644 --- a/docs/services/sharing/_index.md +++ b/docs/services/sharing/_index.md @@ -7,4 +7,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + This service provides sharing functionality. + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/store/_index.md b/docs/services/store/_index.md index 0dc1c2e8e4..9277a24b8d 100644 --- a/docs/services/store/_index.md +++ b/docs/services/store/_index.md @@ -8,4 +8,11 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- +## Abstract + This service provides ... + + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/thumbnails/_index.md b/docs/services/thumbnails/_index.md index c90f2811f3..52935717e2 100644 --- a/docs/services/thumbnails/_index.md +++ b/docs/services/thumbnails/_index.md @@ -8,4 +8,11 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- -This service provides an ocis extensions which generates thumbnails for image files. +## Abstract + +The thumbnail service generates thumbnails for image files. + + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/web/_index.md b/docs/services/web/_index.md index e856f59442..3f2625c4ec 100644 --- a/docs/services/web/_index.md +++ b/docs/services/web/_index.md @@ -8,4 +8,11 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- -This service embeds [ownCloud Web](https://github.com/owncloud/web) to provide a UI for ownCloud Infinite Scale. +## Abstract + +The web service embeds [ownCloud Web](https://github.com/owncloud/web) to provide a UI for ownCloud Infinite Scale. + + +## Table of Contents + +{{< toc-tree >}} diff --git a/docs/services/webdav/_index.md b/docs/services/webdav/_index.md index 6dd82460e1..1ce3ae9eea 100644 --- a/docs/services/webdav/_index.md +++ b/docs/services/webdav/_index.md @@ -1,5 +1,5 @@ --- -title: WebDaV +title: WebDAV date: 2018-05-02T00:00:00+00:00 weight: 20 geekdocRepo: https://github.com/owncloud/ocis @@ -8,4 +8,10 @@ geekdocFilePath: _index.md geekdocCollapseSection: true --- -This service provides the WebDAV API which is required by some ownCloud clients. +## Abstract + +This service provides preview (thumbnails) endpoints on the WebDAV API and therefore extends the main WebDAV API provided by the [oCDAV service]({{ ../../ocdav }}). + +## Table of Contents + +{{< toc-tree >}} diff --git a/ocis-pkg/config/config.go b/ocis-pkg/config/config.go index c5c2f03588..59b88543ac 100644 --- a/ocis-pkg/config/config.go +++ b/ocis-pkg/config/config.go @@ -61,14 +61,14 @@ type Config struct { Mode Mode // DEPRECATED File string - OcisURL string `yaml:"ocis_url"` + OcisURL string `yaml:"ocis_url" desc:"URL, where oCIS is reachable for users."` Registry string `yaml:"registry"` TokenManager *shared.TokenManager `yaml:"token_manager"` MachineAuthAPIKey string `yaml:"machine_auth_api_key" env:"OCIS_MACHINE_AUTH_API_KEY" desc:"Machine auth API key used for accessing the 'auth-machine' service to impersonate users."` TransferSecret string `yaml:"transfer_secret" env:"STORAGE_TRANSFER_SECRET"` - SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID"` - SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY"` + SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID" desc:"ID of the oCIS storage-system system user. Admins need to set the ID for the storage-system system user in this config option which is then used to reference the user. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` + SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY" desc:"API key for the storage-system system user."` AdminUserID string `yaml:"admin_user_id" env:"OCIS_ADMIN_USER_ID" desc:"ID of a user, that should receive admin privileges."` Runtime Runtime `yaml:"runtime"` diff --git a/ocis-pkg/shared/shared_types.go b/ocis-pkg/shared/shared_types.go index ad11437d75..11cfdab191 100644 --- a/ocis-pkg/shared/shared_types.go +++ b/ocis-pkg/shared/shared_types.go @@ -39,12 +39,12 @@ type Reva struct { type Commons struct { Log *Log `yaml:"log"` Tracing *Tracing `yaml:"tracing"` - OcisURL string `yaml:"ocis_url" env:"OCIS_URL"` + OcisURL string `yaml:"ocis_url" env:"OCIS_URL" desc:"URL, where oCIS is reachable for users."` TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` MachineAuthAPIKey string `yaml:"machine_auth_api_key" env:"OCIS_MACHINE_AUTH_API_KEY" desc:"Machine auth API key used for accessing the 'auth-machine' service to impersonate users."` TransferSecret string `yaml:"transfer_secret,omitempty" env:"REVA_TRANSFER_SECRET"` - SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID"` + SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID" desc:"ID of the oCIS storage-system system user. Admins need to set the ID for the storage-system system user in this config option which is then used to reference the user. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` SystemUserAPIKey string `yaml:"system_user_api_key" env:"SYSTEM_USER_API_KEY"` AdminUserID string `yaml:"admin_user_id" env:"OCIS_ADMIN_USER_ID" desc:"ID of a user, that should receive admin privileges."` } diff --git a/ocis/pkg/init/init.go b/ocis/pkg/init/init.go index 8fd77b7a67..733092c5c2 100644 --- a/ocis/pkg/init/init.go +++ b/ocis/pkg/init/init.go @@ -31,10 +31,6 @@ type InsecureProxyExtension struct { InsecureBackends bool `yaml:"insecure_backends"` } -type DataProviderInsecureSettings struct { - DataProviderInsecure bool `yaml:"data_provider_insecure"` -} - type LdapSettings struct { BindPassword string `yaml:"bind_password"` } @@ -114,8 +110,6 @@ type OcisConfig struct { AuthBearer AuthbearerExtension `yaml:"auth_bearer"` Users UsersAndGroupsExtension Groups UsersAndGroupsExtension - StorageSystem DataProviderInsecureSettings `yaml:"storage_system"` - StorageUsers DataProviderInsecureSettings `yaml:"storage_users"` Ocdav InsecureExtension Thumbnails ThumbnailExtension } @@ -289,12 +283,6 @@ func CreateConfig(insecure, forceOverwrite bool, configPath, adminPassword strin cfg.Proxy = InsecureProxyExtension{ InsecureBackends: true, } - cfg.StorageSystem = DataProviderInsecureSettings{ - DataProviderInsecure: true, - } - cfg.StorageUsers = DataProviderInsecureSettings{ - DataProviderInsecure: true, - } cfg.Thumbnails.Thumbnail.WebdavAllowInsecure = true cfg.Thumbnails.Thumbnail.Cs3AllowInsecure = true diff --git a/services/app-provider/pkg/config/config.go b/services/app-provider/pkg/config/config.go index 6536748ee9..454bffb437 100644 --- a/services/app-provider/pkg/config/config.go +++ b/services/app-provider/pkg/config/config.go @@ -52,7 +52,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"APP_PROVIDER_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"APP_PROVIDER_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"APP_PROVIDER_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/app-registry/pkg/config/config.go b/services/app-registry/pkg/config/config.go index 83cc74883e..3c13b65ea3 100644 --- a/services/app-registry/pkg/config/config.go +++ b/services/app-registry/pkg/config/config.go @@ -50,7 +50,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"APP_REGISTRY_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"APP_REGISTRY_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"APP_REGISTRY_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/auth-basic/pkg/config/config.go b/services/auth-basic/pkg/config/config.go index 7660223e9f..c168c61bd7 100644 --- a/services/auth-basic/pkg/config/config.go +++ b/services/auth-basic/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"AUTH_BASIC_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's groupmember ships in the reva access token. To reduces token size, especially when users are members of a large number of groups."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"AUTH_BASIC_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's group memberships in the reva access token. This reduces the token size, especially when users are members of a large number of groups."` AuthProvider string `yaml:"auth_provider" env:"AUTH_BASIC_AUTH_PROVIDER" desc:"The auth provider which should be used by the service (e.g. 'ldap')."` AuthProviders AuthProviders `yaml:"auth_providers"` @@ -51,7 +51,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"AUTH_BASIC_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"AUTH_BASIC_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"AUTH_BASIC_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/auth-bearer/pkg/config/config.go b/services/auth-bearer/pkg/config/config.go index 63ac65d928..3e58369698 100644 --- a/services/auth-bearer/pkg/config/config.go +++ b/services/auth-bearer/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"AUTH_BEARER_SKIP_USER_GROUPS_IN_TOKEN" desc:"Skip storing all groups of a user in the jwt token."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"AUTH_BEARER_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's group memberships in the reva access token. This reduces the token size, especially when users are members of a large number of groups."` OIDC OIDC `yaml:"oidc"` @@ -51,7 +51,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"AUTH_BEARER_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"AUTH_BEARER_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"AUTH_BEARER_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/auth-machine/pkg/config/config.go b/services/auth-machine/pkg/config/config.go index e2a363c3e1..4c4ade07a4 100644 --- a/services/auth-machine/pkg/config/config.go +++ b/services/auth-machine/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"AUTH_MACHINE_SKIP_USER_GROUPS_IN_TOKEN" desc:"Skip storing all groups of a user in the jwt token."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"AUTH_MACHINE_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's group memberships in the reva access token. This reduces the token size, especially when users are members of a large number of groups."` MachineAuthAPIKey string `yaml:"machine_auth_api_key" env:"OCIS_MACHINE_AUTH_API_KEY;AUTH_MACHINE_API_KEY" desc:"Machine auth API key used for validating requests from other services when impersonating users."` @@ -51,7 +51,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"AUTH_MACHINE_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"AUTH_MACHINE_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"AUTH_MACHINE_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/frontend/pkg/config/config.go b/services/frontend/pkg/config/config.go index 06d33ecc2c..4393f6346e 100644 --- a/services/frontend/pkg/config/config.go +++ b/services/frontend/pkg/config/config.go @@ -17,13 +17,13 @@ type Config struct { // JWTSecret used to verify reva access token - TransferSecret string `yaml:"transfer_secret" env:"STORAGE_TRANSFER_SECRET"` + TransferSecret string `yaml:"transfer_secret" env:"STORAGE_TRANSFER_SECRET" desc:"Transfer secret for signing file up- and download requests."` TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - MachineAuthAPIKey string `yaml:"machine_auth_api_key" env:"OCIS_MACHINE_AUTH_API_KEY;FRONTEND_MACHINE_AUTH_API_KEY" desc:"Machine auth API key used for accessing the 'auth-machine' service."` + MachineAuthAPIKey string `yaml:"machine_auth_api_key" env:"OCIS_MACHINE_AUTH_API_KEY;FRONTEND_MACHINE_AUTH_API_KEY" desc:"Machine auth API key used for accessing the 'auth-machine' service to impersonate users."` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"FRONTEND_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's group memberships in the reva access token. This reduces token size, especially when users are members of a large number of groups."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"FRONTEND_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` EnableFavorites bool `yaml:"enable_favorites" env:"FRONTEND_ENABLE_FAVORITES" desc:"Enables the support for favorites in the frontend."` EnableProjectSpaces bool `yaml:"enable_project_spaces" env:"FRONTEND_ENABLE_PROJECT_SPACES" desc:"Indicates to clients that project spaces are supposed to be made available."` @@ -72,7 +72,7 @@ type Debug struct { } type HTTPConfig struct { - Addr string `yaml:"addr" env:"FRONTEND_HTTP_ADDR" desc:"The address of the http service."` + Addr string `yaml:"addr" env:"FRONTEND_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"FRONTEND_HTTP_PROTOCOL" desc:"The transport protocol of the http service."` Prefix string `yaml:"prefix" env:"FRONTEND_HTTP_PREFIX" desc:"The Path prefix where the frontend can be accessed (defaults to /)."` diff --git a/services/gateway/pkg/config/config.go b/services/gateway/pkg/config/config.go index a3aac759d9..bb2c023ca9 100644 --- a/services/gateway/pkg/config/config.go +++ b/services/gateway/pkg/config/config.go @@ -19,15 +19,14 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"GATEWAY_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's groupmember ships in the reva access token. To reduces token size, especially when users are members of a large number of groups."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"GATEWAY_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` - CommitShareToStorageGrant bool `yaml:"commit_share_to_storage_grant" env:"GATEWAY_COMMIT_SHARE_TO_STORAGE_GRANT" desc:"Commit shares to storage grants (default: true)."` - CommitShareToStorageRef bool `yaml:"commit_share_to_storage_ref" env:"GATEWAY_COMMIT_SHARE_TO_STORAGE_REF" desc:"Commit shares to storage (default: true)"` - ShareFolder string `yaml:"share_folder_name" env:"GATEWAY_SHARE_FOLDER_NAME" desc:"Name of the gateway share folder"` - DisableHomeCreationOnLogin bool `yaml:"disable_home_creation_on_login" env:"GATEWAY_DISABLE_HOME_CREATION_ON_LOGIN" desc:"Disable creation of the homespace on login"` + CommitShareToStorageGrant bool `yaml:"commit_share_to_storage_grant" env:"GATEWAY_COMMIT_SHARE_TO_STORAGE_GRANT" desc:"Commit shares to storage grants. This grants access to shared resources for the share receiver directly on the storage."` + ShareFolder string `yaml:"share_folder_name" env:"GATEWAY_SHARE_FOLDER_NAME" desc:"Name of the share folder in users' home space."` + DisableHomeCreationOnLogin bool `yaml:"disable_home_creation_on_login" env:"GATEWAY_DISABLE_HOME_CREATION_ON_LOGIN" desc:"Disable creation of the home space on login."` TransferSecret string `yaml:"transfer_secret" env:"STORAGE_TRANSFER_SECRET" desc:"The storage transfer secret"` // TODO: how to name the env TransferExpires int `yaml:"transfer_expires" env:"GATEWAY_TRANSFER_EXPIRES" desc:"Expiry for the gateway tokens"` - EtagCacheTTL int `yaml:"etag_cache_ttl" env:"GATEWAY_ETAG_CACHE_TTL" desc:"Max TTL for the gatways ETAG cache."` + EtagCacheTTL int `yaml:"etag_cache_ttl" env:"GATEWAY_ETAG_CACHE_TTL" desc:"Max TTL in seconds for the gateway's ETAG cache."` FrontendPublicURL string `yaml:"frontend_public_url" env:"OCIS_URL;GATEWAY_FRONTEND_PUBLIC_URL" desc:"The public facing url of the ocis frontend."` @@ -74,7 +73,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"GATEWAY_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"GATEWAY_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"GATEWAY_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/gateway/pkg/config/defaults/defaultconfig.go b/services/gateway/pkg/config/defaults/defaultconfig.go index 34d36e16ed..cd2d2bacad 100644 --- a/services/gateway/pkg/config/defaults/defaultconfig.go +++ b/services/gateway/pkg/config/defaults/defaultconfig.go @@ -32,7 +32,6 @@ func DefaultConfig() *config.Config { }, CommitShareToStorageGrant: true, - CommitShareToStorageRef: true, ShareFolder: "Shares", DisableHomeCreationOnLogin: true, TransferExpires: 24 * 60 * 60, diff --git a/services/gateway/pkg/revaconfig/config.go b/services/gateway/pkg/revaconfig/config.go index 3d9850a9c0..3d6fa39b3c 100644 --- a/services/gateway/pkg/revaconfig/config.go +++ b/services/gateway/pkg/revaconfig/config.go @@ -45,7 +45,6 @@ func GatewayConfigFromStruct(cfg *config.Config, logger log.Logger) map[string]i "publicshareprovidersvc": cfg.SharingEndpoint, "ocmshareprovidersvc": cfg.SharingEndpoint, "commit_share_to_storage_grant": cfg.CommitShareToStorageGrant, - "commit_share_to_storage_ref": cfg.CommitShareToStorageRef, "share_folder": cfg.ShareFolder, // ShareFolder is the location where to create shares in the recipient's storage provider. // other "disable_home_creation_on_login": cfg.DisableHomeCreationOnLogin, diff --git a/services/graph-explorer/pkg/config/http.go b/services/graph-explorer/pkg/config/http.go index 54f9c6bc63..b09f2492dd 100644 --- a/services/graph-explorer/pkg/config/http.go +++ b/services/graph-explorer/pkg/config/http.go @@ -2,8 +2,8 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"GRAPH_EXPLORER_HTTP_ADDR" desc:"The HTTP service address."` - Root string `yaml:"root" env:"GRAPH_EXPLORER_HTTP_ROOT" desc:"The HTTP service root path."` + Addr string `yaml:"addr" env:"GRAPH_EXPLORER_HTTP_ADDR" desc:"The bind address of the HTTP service."` + Root string `yaml:"root" env:"GRAPH_EXPLORER_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` Namespace string `yaml:"-"` } diff --git a/services/graph/pkg/config/http.go b/services/graph/pkg/config/http.go index e8da11aa27..86784b67f9 100644 --- a/services/graph/pkg/config/http.go +++ b/services/graph/pkg/config/http.go @@ -2,7 +2,7 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"GRAPH_HTTP_ADDR"` + Addr string `yaml:"addr" env:"GRAPH_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` - Root string `yaml:"root" env:"GRAPH_HTTP_ROOT"` + Root string `yaml:"root" env:"GRAPH_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` } diff --git a/services/groups/pkg/config/config.go b/services/groups/pkg/config/config.go index 55d6dcf9ca..569aa46406 100644 --- a/services/groups/pkg/config/config.go +++ b/services/groups/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"GROUPS_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's groupmember ships in the reva access token. To reduces token size, especially when users are members of a large number of groups."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"GROUPS_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` Driver string `yaml:"driver" desc:"The driver which should be used by the groups service (e.g. ldap)."` Drivers Drivers `yaml:"drivers"` @@ -52,7 +52,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"GROUPS_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"GROUPS_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"GROUPS_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/idp/pkg/config/config.go b/services/idp/pkg/config/config.go index 4bf4310de7..5ce0481f99 100644 --- a/services/idp/pkg/config/config.go +++ b/services/idp/pkg/config/config.go @@ -53,7 +53,7 @@ type Ldap struct { // Asset defines the available asset configuration. type Asset struct { - Path string `yaml:"asset" env:"IDP_ASSET_PATH" desc:"Defines the path for the IDP assets."` + Path string `yaml:"asset" env:"IDP_ASSET_PATH" desc:"Serve IDP assets from a path on the filesystem instead of the builtin assets."` } type Client struct { diff --git a/services/idp/pkg/config/http.go b/services/idp/pkg/config/http.go index 616449c0e7..8051caa736 100644 --- a/services/idp/pkg/config/http.go +++ b/services/idp/pkg/config/http.go @@ -2,8 +2,8 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"IDP_HTTP_ADDR"` - Root string `yaml:"root" env:"IDP_HTTP_ROOT"` + Addr string `yaml:"addr" env:"IDP_HTTP_ADDR" desc:"The bind address of the HTTP service."` + Root string `yaml:"root" env:"IDP_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` Namespace string `yaml:"-"` TLSCert string `yaml:"tls_cert" env:"IDP_TRANSPORT_TLS_CERT"` TLSKey string `yaml:"tls_key" env:"IDP_TRANSPORT_TLS_KEY"` diff --git a/services/ocdav/pkg/config/config.go b/services/ocdav/pkg/config/config.go index 4bf2d76995..cbd33b6ffc 100644 --- a/services/ocdav/pkg/config/config.go +++ b/services/ocdav/pkg/config/config.go @@ -18,18 +18,18 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"OCDAV_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's group memberships in the reva access token. This reduces token size, especially when users are members of a large number of groups."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"OCDAV_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` WebdavNamespace string `yaml:"webdav_namespace" env:"OCDAV_WEBDAV_NAMESPACE" desc:"Jail requests to /dav/webdav into this CS3 namespace. Supports template layouting with CS3 User properties."` FilesNamespace string `yaml:"files_namespace" env:"OCDAV_FILES_NAMESPACE" desc:"Jail requests to /dav/files/{username} into this CS3 namespace. Supports template layouting with CS3 User properties."` SharesNamespace string `yaml:"shares_namespace" env:"OCDAV_SHARES_NAMESPACE" desc:"The human readable path for the share jail. Relative to a users personal space root. Upcased intentionally."` // PublicURL used to redirect /s/{token} URLs to - PublicURL string `yaml:"public_url" env:"OCIS_URL;OCDAV_PUBLIC_URL"` + PublicURL string `yaml:"public_url" env:"OCIS_URL;OCDAV_PUBLIC_URL" desc:"URL, where oCIS is reachable for users."` // Insecure certificates allowed when making requests to the gateway Insecure bool `yaml:"insecure" env:"OCIS_INSECURE;OCDAV_INSECURE"` // Timeout in seconds when making requests to the gateway - Timeout int64 `yaml:"gateway_request_timeout" env:"OCDAV_GATEWAY_REQUEST_TIMEOUT" desc:"Request timeout for ocdav gateway.` + Timeout int64 `yaml:"gateway_request_timeout" env:"OCDAV_GATEWAY_REQUEST_TIMEOUT" desc:"Request timeout in seconds for requests from the oCDAV service to the gateway service."` Middleware Middleware `yaml:"middleware"` Context context.Context `yaml:"-"` @@ -61,7 +61,7 @@ type Debug struct { } type HTTPConfig struct { - Addr string `yaml:"addr" env:"OCDAV_HTTP_ADDR" desc:"The address of the http service."` + Addr string `yaml:"addr" env:"OCDAV_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"OCDAV_HTTP_PROTOCOL" desc:"The transport protocol of the http service."` Prefix string `yaml:"prefix" env:"OCDAV_HTTP_PREFIX" desc:"A URL path prefix for the handler."` diff --git a/services/ocs/pkg/config/http.go b/services/ocs/pkg/config/http.go index 115bc4b7a8..6ba7df2081 100644 --- a/services/ocs/pkg/config/http.go +++ b/services/ocs/pkg/config/http.go @@ -2,8 +2,8 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"OCS_HTTP_ADDR"` - Root string `yaml:"root" env:"OCS_HTTP_ROOT"` + Addr string `yaml:"addr" env:"OCS_HTTP_ADDR" desc:"The bind address of the HTTP service."` + Root string `yaml:"root" env:"OCS_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` Namespace string `yaml:"-"` CORS CORS `yaml:"cors"` } diff --git a/services/proxy/pkg/config/config.go b/services/proxy/pkg/config/config.go index 3246660dcd..c68f959757 100644 --- a/services/proxy/pkg/config/config.go +++ b/services/proxy/pkg/config/config.go @@ -30,8 +30,8 @@ type Config struct { UserCS3Claim string `yaml:"user_cs3_claim" env:"PROXY_USER_CS3_CLAIM" desc:"The name of a CS3 user attribute (claim) that should be mapped to the 'user_oidc_claim'. Currently defaults to 'mail' (other possible values are: 'username', 'displayname')"` MachineAuthAPIKey string `yaml:"machine_auth_api_key" env:"OCIS_MACHINE_AUTH_API_KEY;PROXY_MACHINE_AUTH_API_KEY" desc:"Machine auth API key used for accessing the 'auth-machine' service to impersonate users."` AutoprovisionAccounts bool `yaml:"auto_provision_accounts" env:"PROXY_AUTOPROVISION_ACCOUNTS" desc:"Set this to 'true' to automatically provsion users that do not yet exist in the users service on-demand upon first signin. To use this a write-enabled libregraph user backend needs to be setup an running."` - EnableBasicAuth bool `yaml:"enable_basic_auth" env:"PROXY_ENABLE_BASIC_AUTH" desc:"Set this to true to enable 'basic' (username/password) authentication. (Default: false)"` - InsecureBackends bool `yaml:"insecure_backends" env:"PROXY_INSECURE_BACKENDS" desc:"Disable TLS certificate validation for all http backend connections. (Default: false)"` + EnableBasicAuth bool `yaml:"enable_basic_auth" env:"PROXY_ENABLE_BASIC_AUTH" desc:"Set this to true to enable 'basic' (username/password) authentication."` + InsecureBackends bool `yaml:"insecure_backends" env:"PROXY_INSECURE_BACKENDS" desc:"Disable TLS certificate validation for all http backend connections."` AuthMiddleware AuthMiddleware `yaml:"auth_middleware"` Context context.Context `yaml:"-"` diff --git a/services/proxy/pkg/config/http.go b/services/proxy/pkg/config/http.go index e57452948d..10d979eb4d 100644 --- a/services/proxy/pkg/config/http.go +++ b/services/proxy/pkg/config/http.go @@ -2,8 +2,8 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"PROXY_HTTP_ADDR"` - Root string `yaml:"root" env:"PROXY_HTTP_ROOT"` + Addr string `yaml:"addr" env:"PROXY_HTTP_ADDR" desc:"The bind address of the HTTP service."` + Root string `yaml:"root" env:"PROXY_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` Namespace string `yaml:"-"` TLSCert string `yaml:"tls_cert" env:"PROXY_TRANSPORT_TLS_CERT"` TLSKey string `yaml:"tls_key" env:"PROXY_TRANSPORT_TLS_KEY"` diff --git a/services/search/pkg/config/grpc.go b/services/search/pkg/config/grpc.go index 89593b5293..51fd97212f 100644 --- a/services/search/pkg/config/grpc.go +++ b/services/search/pkg/config/grpc.go @@ -2,6 +2,6 @@ package config // GRPC defines the available grpc configuration. type GRPC struct { - Addr string `ocisConfig:"addr" env:"SEARCH_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `ocisConfig:"addr" env:"SEARCH_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `ocisConfig:"-" yaml:"-"` } diff --git a/services/search/pkg/config/http.go b/services/search/pkg/config/http.go index 018f8c551f..f02266fd2d 100644 --- a/services/search/pkg/config/http.go +++ b/services/search/pkg/config/http.go @@ -2,7 +2,7 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `ocisConfig:"addr" env:"SEARCH_HTTP_ADDR"` + Addr string `ocisConfig:"addr" env:"SEARCH_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `ocisConfig:"-" yaml:"-"` - Root string `ocisConfig:"root" env:"SEARCH_HTTP_ROOT"` + Root string `ocisConfig:"root" env:"SEARCH_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` } diff --git a/services/settings/pkg/config/config.go b/services/settings/pkg/config/config.go index 87fbaa7ebf..9e0c42d465 100644 --- a/services/settings/pkg/config/config.go +++ b/services/settings/pkg/config/config.go @@ -19,8 +19,8 @@ type Config struct { HTTP HTTP `yaml:"http"` GRPC GRPC `yaml:"grpc"` - StoreType string `yaml:"store_type" env:"SETTINGS_STORE_TYPE"` - DataPath string `yaml:"data_path" env:"SETTINGS_DATA_PATH"` + StoreType string `yaml:"store_type" env:"SETTINGS_STORE_TYPE" desc:"Store type configures the persistency driver. Possible values are \"metadata\" and \"filesystem\"."` + DataPath string `yaml:"data_path" env:"SETTINGS_DATA_PATH" desc:"Path for the persistence directory."` Metadata Metadata `yaml:"metadata_config"` AdminUserID string `yaml:"admin_user_id" env:"OCIS_ADMIN_USER_ID;SETTINGS_ADMIN_USER_ID" desc:"ID of a user, that should receive admin privileges."` @@ -35,15 +35,15 @@ type Config struct { // Asset defines the available asset configuration. type Asset struct { - Path string `yaml:"path" env:"SETTINGS_ASSET_PATH"` + Path string `yaml:"path" env:"SETTINGS_ASSET_PATH" desc:"Serve settings Web UI assets from a path on the filesystem instead of the builtin assets. Can be used for development and customization."` } // Metadata configures the metadata store to use type Metadata struct { - GatewayAddress string `yaml:"gateway_addr" env:"STORAGE_GATEWAY_GRPC_ADDR"` - StorageAddress string `yaml:"storage_addr" env:"STORAGE_GRPC_ADDR"` + GatewayAddress string `yaml:"gateway_addr" env:"STORAGE_GATEWAY_GRPC_ADDR" desc:"GRPC address of the storage-system service."` + StorageAddress string `yaml:"storage_addr" env:"STORAGE_GRPC_ADDR" desc:"GRPC address of the storage-system service."` - SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID;SETTINGS_SYSTEM_USER_ID"` - SystemUserIDP string `yaml:"system_user_idp" env:"OCIS_SYSTEM_USER_IDP;SETTINGS_SYSTEM_USER_IDP"` - SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY"` + SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID;SETTINGS_SYSTEM_USER_ID" desc:"ID of the oCIS storage-system system user. Admins need to set the ID for the storage-system system user in this config option which is then used to reference the user. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` + SystemUserIDP string `yaml:"system_user_idp" env:"OCIS_SYSTEM_USER_IDP;SETTINGS_SYSTEM_USER_IDP" desc:"IDP of the oCIS storage-system system user."` + SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY" desc:"API key for the storage-system system user."` } diff --git a/services/settings/pkg/config/grpc.go b/services/settings/pkg/config/grpc.go index f6f8a0f0d3..1acae9e300 100644 --- a/services/settings/pkg/config/grpc.go +++ b/services/settings/pkg/config/grpc.go @@ -2,6 +2,6 @@ package config // GRPC defines the available grpc configuration. type GRPC struct { - Addr string `yaml:"addr" env:"SETTINGS_GRPC_ADDR"` + Addr string `yaml:"addr" env:"SETTINGS_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` } diff --git a/services/settings/pkg/config/http.go b/services/settings/pkg/config/http.go index 5b212af05c..df764c7797 100644 --- a/services/settings/pkg/config/http.go +++ b/services/settings/pkg/config/http.go @@ -2,10 +2,10 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"SETTINGS_HTTP_ADDR"` + Addr string `yaml:"addr" env:"SETTINGS_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` - Root string `yaml:"root" env:"SETTINGS_HTTP_ROOT"` - CacheTTL int `yaml:"cache_ttl" env:"SETTINGS_CACHE_TTL"` + Root string `yaml:"root" env:"SETTINGS_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` + CacheTTL int `yaml:"cache_ttl" env:"SETTINGS_CACHE_TTL" desc:"Browser cache control max-age value in seconds for settings Web UI assets."` CORS CORS `yaml:"cors"` } diff --git a/services/sharing/pkg/config/config.go b/services/sharing/pkg/config/config.go index 1275352758..dcb801239f 100644 --- a/services/sharing/pkg/config/config.go +++ b/services/sharing/pkg/config/config.go @@ -19,11 +19,11 @@ type Config struct { Reva *Reva `yaml:"reva"` Events Events `yaml:"events"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"SHARING_SKIP_USER_GROUPS_IN_TOKEN"` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"SHARING_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` - UserSharingDriver string `yaml:"user_sharing_driver" env:"SHARING_USER_DRIVER"` + UserSharingDriver string `yaml:"user_sharing_driver" env:"SHARING_USER_DRIVER" desc:"Driver to be used to persist shares. Possible values: \"json\", \"cs3\", \"owncloudsql\""` UserSharingDrivers UserSharingDrivers `yaml:"user_sharing_drivers"` - PublicSharingDriver string `yaml:"public_sharing_driver" env:"SHARING_PUBLIC_DRIVER"` + PublicSharingDriver string `yaml:"public_sharing_driver" env:"SHARING_PUBLIC_DRIVER" desc:"Driver to be used to persist public shares. Possible values: \"json\", \"cs3\""` PublicSharingDrivers PublicSharingDrivers `yaml:"public_sharing_drivers"` Supervised bool `yaml:"-"` @@ -55,7 +55,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"SHARING_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"SHARING_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"SHARING_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } @@ -69,7 +69,7 @@ type UserSharingDrivers struct { } type UserSharingJSONDriver struct { - File string `yaml:"file" env:"SHARING_USER_JSON_FILE"` + File string `yaml:"file" env:"SHARING_USER_JSON_FILE" desc:"Path to the json file where shares will be persisted."` } type UserSharingSQLDriver struct { @@ -85,19 +85,19 @@ type UserSharingSQLDriver struct { } type UserSharingOwnCloudSQLDriver struct { - DBUsername string `yaml:"db_username" env:"SHARING_USER_OWNCLOUDSQL_DB_USERNAME"` - DBPassword string `yaml:"db_password" env:"SHARING_USER_OWNCLOUDSQL_DB_PASSWORD"` - DBHost string `yaml:"db_host" env:"SHARING_USER_OWNCLOUDSQL_DB_HOST"` - DBPort int `yaml:"db_port" env:"SHARING_USER_OWNCLOUDSQL_DB_PORT"` - DBName string `yaml:"db_name" env:"SHARING_USER_OWNCLOUDSQL_DB_NAME"` - UserStorageMountID string `yaml:"user_storage_mount_id" env:"SHARING_USER_OWNCLOUDSQL_USER_STORAGE_MOUNT_ID"` + DBUsername string `yaml:"db_username" env:"SHARING_USER_OWNCLOUDSQL_DB_USERNAME" desc:"Username for the database."` + DBPassword string `yaml:"db_password" env:"SHARING_USER_OWNCLOUDSQL_DB_PASSWORD" desc:"Password for the database."` + DBHost string `yaml:"db_host" env:"SHARING_USER_OWNCLOUDSQL_DB_HOST" desc:"Hostname or IP of the database server."` + DBPort int `yaml:"db_port" env:"SHARING_USER_OWNCLOUDSQL_DB_PORT" desc:"Port that the database server is listening on."` + DBName string `yaml:"db_name" env:"SHARING_USER_OWNCLOUDSQL_DB_NAME" desc:"Name of the database to be used."` + UserStorageMountID string `yaml:"user_storage_mount_id" env:"SHARING_USER_OWNCLOUDSQL_USER_STORAGE_MOUNT_ID" desc:"Mount ID of the ownCloudSQL users storage for mapping ownCloud 10 shares."` } type UserSharingCS3Driver struct { - ProviderAddr string `yaml:"provider_addr" env:"SHARING_USER_CS3_PROVIDER_ADDR"` - SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID;SHARING_USER_CS3_SYSTEM_USER_ID"` - SystemUserIDP string `yaml:"system_user_idp" env:"OCIS_SYSTEM_USER_IDP;SHARING_USER_CS3_SYSTEM_USER_IDP"` - SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY;SHARING_USER_CS3_SYSTEM_USER_API_KEY"` + ProviderAddr string `yaml:"provider_addr" env:"SHARING_USER_CS3_PROVIDER_ADDR" desc:"GRPC address of the storage-system extension."` + SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID;SHARING_USER_CS3_SYSTEM_USER_ID" desc:"ID of the oCIS storage-system system user. Admins need to set the ID for the storage-system system user in this config option which is then used to reference the user. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` + SystemUserIDP string `yaml:"system_user_idp" env:"OCIS_SYSTEM_USER_IDP;SHARING_USER_CS3_SYSTEM_USER_IDP" desc:"IDP of the oCIS storage-system system user."` + SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY;SHARING_USER_CS3_SYSTEM_USER_API_KEY" desc:"API key for the storage-system system user."` } type PublicSharingDrivers struct { @@ -108,7 +108,7 @@ type PublicSharingDrivers struct { } type PublicSharingJSONDriver struct { - File string `yaml:"file" env:"SHARING_PUBLIC_JSON_FILE"` + File string `yaml:"file" env:"SHARING_PUBLIC_JSON_FILE" desc:"Path to the JSON file where public share meta-data will be stored. This JSON file contains the information about public shares that have been created."` } type PublicSharingSQLDriver struct { @@ -124,10 +124,10 @@ type PublicSharingSQLDriver struct { } type PublicSharingCS3Driver struct { - ProviderAddr string `yaml:"provider_addr" env:"SHARING_PUBLIC_CS3_PROVIDER_ADDR"` - SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID;SHARING_PUBLIC_CS3_SYSTEM_USER_ID"` - SystemUserIDP string `yaml:"system_user_idp" env:"OCIS_SYSTEM_USER_IDP;SHARING_PUBLIC_CS3_SYSTEM_USER_IDP"` - SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY;SHARING_USER_CS3_SYSTEM_USER_API_KEY"` + ProviderAddr string `yaml:"provider_addr" env:"SHARING_PUBLIC_CS3_PROVIDER_ADDR" desc:"GRPC address of the storage-system extension."` + SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID;SHARING_PUBLIC_CS3_SYSTEM_USER_ID" desc:"ID of the oCIS storage-system system user. Admins need to set the ID for the storage-system system user in this config option which is then used to reference the user. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` + SystemUserIDP string `yaml:"system_user_idp" env:"OCIS_SYSTEM_USER_IDP;SHARING_PUBLIC_CS3_SYSTEM_USER_IDP" desc:"IDP of the oCIS storage-system system user."` + SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY;SHARING_USER_CS3_SYSTEM_USER_API_KEY" desc:"API key for the storage-system system user."` } type Events struct { diff --git a/services/storage-publiclink/pkg/config/config.go b/services/storage-publiclink/pkg/config/config.go index 159f4c8de1..9faf48a934 100644 --- a/services/storage-publiclink/pkg/config/config.go +++ b/services/storage-publiclink/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_PUBLICLINK_SKIP_USER_GROUPS_IN_TOKEN"` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_PUBLICLINK_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` StorageProvider StorageProvider `yaml:"storage_provider"` @@ -51,11 +51,11 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"STORAGE_PUBLICLINK_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"STORAGE_PUBLICLINK_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"STORAGE_PUBLICLINK_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } type StorageProvider struct { - MountID string `yaml:"mount_id" env:"STORAGE_PUBLICLINK_STORAGE_PROVIDER_MOUNT_ID"` + MountID string `yaml:"mount_id" env:"STORAGE_PUBLICLINK_STORAGE_PROVIDER_MOUNT_ID" desc:"Mount ID of this storage."` } diff --git a/services/storage-shares/pkg/config/config.go b/services/storage-shares/pkg/config/config.go index 6ee4621e42..3e8da9996d 100644 --- a/services/storage-shares/pkg/config/config.go +++ b/services/storage-shares/pkg/config/config.go @@ -18,11 +18,11 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_SHARES_SKIP_USER_GROUPS_IN_TOKEN"` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_SHARES_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` - MountID string `yaml:"mount_id" env:"STORAGE_SHARES_MOUNT_ID"` - ReadOnly bool `yaml:"readonly" env:"STORAGE_SHARES_READ_ONLY"` - SharesProviderEndpoint string `yaml:"user_share_provider_endpoint" env:"STORAGE_SHARES_USER_SHARE_PROVIDER_ENDPOINT"` + MountID string `yaml:"mount_id" env:"STORAGE_SHARES_MOUNT_ID" desc:"Mount ID of this storage. Admins can set the ID for the storage in this config option manually which is then used to reference the storage. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` + ReadOnly bool `yaml:"readonly" env:"STORAGE_SHARES_READ_ONLY" desc:"Set this storage to be read-only."` + SharesProviderEndpoint string `yaml:"user_share_provider_endpoint" env:"STORAGE_SHARES_USER_SHARE_PROVIDER_ENDPOINT" desc:"GRPC endpoint of the sharing extension."` Supervised bool `yaml:"-"` Context context.Context `yaml:"-"` @@ -53,7 +53,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"STORAGE_SHARES_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"STORAGE_SHARES_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"STORAGE_SHARES_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/storage-system/pkg/config/config.go b/services/storage-system/pkg/config/config.go index 6452595e61..77804959e8 100644 --- a/services/storage-system/pkg/config/config.go +++ b/services/storage-system/pkg/config/config.go @@ -19,16 +19,14 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID"` - SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY"` + SystemUserID string `yaml:"system_user_id" env:"OCIS_SYSTEM_USER_ID" desc:"ID of the oCIS storage-system system user. Admins need to set the ID for the storage-system system user in this config option which is then used to reference the user. Any reasonable long string is possible, preferably this would be an UUIDv4 format."` + SystemUserAPIKey string `yaml:"system_user_api_key" env:"OCIS_SYSTEM_USER_API_KEY" desc:"API key for the storage-system system user."` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_SYSTEM_SKIP_USER_GROUPS_IN_TOKEN"` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_SYSTEM_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` - Driver string `yaml:"driver" env:"STORAGE_SYSTEM_DRIVER" desc:"The driver which should be used by the service"` - Drivers Drivers `yaml:"drivers"` - DataServerURL string `yaml:"data_server_url" env:"STORAGE_SYSTEM_DATA_SERVER_URL"` - TempFolder string `yaml:"temp_folder" env:"STORAGE_SYSTEM_TEMP_FOLDER"` - DataProviderInsecure bool `yaml:"data_provider_insecure" env:"OCIS_INSECURE;STORAGE_SYSTEM_DATAPROVIDER_INSECURE"` + Driver string `yaml:"driver" env:"STORAGE_SYSTEM_DRIVER" desc:"The driver which should be used by the service"` + Drivers Drivers `yaml:"drivers"` + DataServerURL string `yaml:"data_server_url" env:"STORAGE_SYSTEM_DATA_SERVER_URL" desc:"URL of the data server, needs to be reachable by services using this service."` Supervised bool `yaml:"-"` Context context.Context `yaml:"-"` @@ -59,13 +57,13 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"STORAGE_SYSTEM_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"STORAGE_SYSTEM_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"STORAGE_SYSTEM_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } type HTTPConfig struct { - Addr string `yaml:"addr" env:"STORAGE_SYSTEM_HTTP_ADDR" desc:"The address of the http service."` + Addr string `yaml:"addr" env:"STORAGE_SYSTEM_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"STORAGE_SYSTEM_HTTP_PROTOCOL" desc:"The transport protocol of the http service."` } @@ -76,7 +74,7 @@ type Drivers struct { type OCISDriver struct { // Root is the absolute path to the location of the data - Root string `yaml:"root" env:"STORAGE_SYSTEM_OCIS_ROOT"` + Root string `yaml:"root" env:"STORAGE_SYSTEM_OCIS_ROOT" desc:"Path for the directory where the storage-system service stores it's persistent data."` } type Events struct { diff --git a/services/storage-system/pkg/config/defaults/defaultconfig.go b/services/storage-system/pkg/config/defaults/defaultconfig.go index 48f0bf6bff..f5daefdfa0 100644 --- a/services/storage-system/pkg/config/defaults/defaultconfig.go +++ b/services/storage-system/pkg/config/defaults/defaultconfig.go @@ -38,7 +38,6 @@ func DefaultConfig() *config.Config { Reva: &config.Reva{ Address: "127.0.0.1:9142", }, - TempFolder: filepath.Join(defaults.BaseDataPath(), "tmp", "metadata"), DataServerURL: "http://localhost:9216/data", Driver: "ocis", Drivers: config.Drivers{ diff --git a/services/storage-system/pkg/revaconfig/config.go b/services/storage-system/pkg/revaconfig/config.go index bbe33e6151..99e50e562b 100644 --- a/services/storage-system/pkg/revaconfig/config.go +++ b/services/storage-system/pkg/revaconfig/config.go @@ -94,7 +94,6 @@ func StorageSystemFromStruct(cfg *config.Config) map[string]interface{} { "driver": cfg.Driver, "drivers": metadataDrivers(cfg), "data_server_url": cfg.DataServerURL, - "tmp_folder": cfg.TempFolder, }, }, }, @@ -104,12 +103,9 @@ func StorageSystemFromStruct(cfg *config.Config) map[string]interface{} { // no datagateway needed as the metadata clients directly talk to the dataprovider with the simple protocol "services": map[string]interface{}{ "dataprovider": map[string]interface{}{ - "prefix": "data", - "driver": cfg.Driver, - "drivers": metadataDrivers(cfg), - "timeout": 86400, - "insecure": cfg.DataProviderInsecure, - "disable_tus": true, + "prefix": "data", + "driver": cfg.Driver, + "drivers": metadataDrivers(cfg), }, }, }, diff --git a/services/storage-users/pkg/config/config.go b/services/storage-users/pkg/config/config.go index 49401b6577..d29a1b96ce 100644 --- a/services/storage-users/pkg/config/config.go +++ b/services/storage-users/pkg/config/config.go @@ -19,17 +19,15 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_USERS_SKIP_USER_GROUPS_IN_TOKEN"` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"STORAGE_USERS_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` - Driver string `yaml:"driver" env:"STORAGE_USERS_DRIVER" desc:"The storage driver which should be used by the service"` - Drivers Drivers `yaml:"drivers"` - DataServerURL string `yaml:"data_server_url" env:"STORAGE_USERS_DATA_SERVER_URL"` - TempFolder string `yaml:"temp_folder" env:"STORAGE_USERS_TEMP_FOLDER"` - DataProviderInsecure bool `yaml:"data_provider_insecure" env:"OCIS_INSECURE;STORAGE_USERS_DATAPROVIDER_INSECURE"` - Events Events `yaml:"events"` - MountID string `yaml:"mount_id" env:"STORAGE_USERS_MOUNT_ID"` - ExposeDataServer bool `yaml:"expose_data_server" env:"STORAGE_USERS_EXPOSE_DATA_SERVER"` - ReadOnly bool `yaml:"readonly" env:"STORAGE_USERS_READ_ONLY"` + Driver string `yaml:"driver" env:"STORAGE_USERS_DRIVER" desc:"The storage driver which should be used by the service"` + Drivers Drivers `yaml:"drivers"` + DataServerURL string `yaml:"data_server_url" env:"STORAGE_USERS_DATA_SERVER_URL" desc:"URL of the data server, needs to be reachable by the data gateway provided by the frontend service or the user if directly exposed."` + Events Events `yaml:"events"` + MountID string `yaml:"mount_id" env:"STORAGE_USERS_MOUNT_ID" desc:"Mount ID of this storage."` + ExposeDataServer bool `yaml:"expose_data_server" env:"STORAGE_USERS_EXPOSE_DATA_SERVER" desc:"Exposes the data server directly to users and bypasses the data gateway. Ensure that the data server address is reachable by users."` + ReadOnly bool `yaml:"readonly" env:"STORAGE_USERS_READ_ONLY" desc:"Set this storage to be read-only."` Supervised bool `yaml:"-"` Context context.Context `yaml:"-"` @@ -60,13 +58,13 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"STORAGE_USERS_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"STORAGE_USERS_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"STORAGE_USERS_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } type HTTPConfig struct { - Addr string `yaml:"addr" env:"STORAGE_USERS_HTTP_ADDR" desc:"The address of the http service."` + Addr string `yaml:"addr" env:"STORAGE_USERS_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"STORAGE_USERS_HTTP_PROTOCOL" desc:"The transport protocol of the http service."` Prefix string @@ -84,52 +82,52 @@ type Drivers struct { type OCISDriver struct { // Root is the absolute path to the location of the data - Root string `yaml:"root" env:"STORAGE_USERS_OCIS_ROOT"` - UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_OCIS_USER_LAYOUT"` - PermissionsEndpoint string `yaml:"permissions_endpoint" env:"STORAGE_USERS_PERMISSION_ENDPOINT,STORAGE_USERS_OCIS_PERMISSIONS_ENDPOINT"` + Root string `yaml:"root" env:"STORAGE_USERS_OCIS_ROOT" desc:"Path for the persistence directory."` + UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_OCIS_USER_LAYOUT" desc:"Template string for the user storage layout in the persistence directory."` + PermissionsEndpoint string `yaml:"permissions_endpoint" env:"STORAGE_USERS_PERMISSION_ENDPOINT,STORAGE_USERS_OCIS_PERMISSIONS_ENDPOINT" desc:"Endpoint of the permissions service."` // PersonalSpaceAliasTemplate contains the template used to construct // the personal space alias, eg: `"{{.SpaceType}}/{{.User.Username | lower}}"` - PersonalSpaceAliasTemplate string `yaml:"personalspacealias_template" env:"STORAGE_USERS_OCIS_PERSONAL_SPACE_ALIAS_TEMPLATE"` + PersonalSpaceAliasTemplate string `yaml:"personalspacealias_template" env:"STORAGE_USERS_OCIS_PERSONAL_SPACE_ALIAS_TEMPLATE" desc:"Template string to construct personal space aliases."` // GeneralSpaceAliasTemplate contains the template used to construct // the general space alias, eg: `{{.SpaceType}}/{{.SpaceName | replace " " "-" | lower}}` - GeneralSpaceAliasTemplate string `yaml:"generalspacealias_template" env:"STORAGE_USERS_OCIS_GENERAL_SPACE_ALIAS_TEMPLATE"` + GeneralSpaceAliasTemplate string `yaml:"generalspacealias_template" env:"STORAGE_USERS_OCIS_GENERAL_SPACE_ALIAS_TEMPLATE" desc:"Template string to construct general space aliases."` //ShareFolder defines the name of the folder jailing all shares - ShareFolder string `yaml:"share_folder" env:"STORAGE_USERS_OCIS_SHARE_FOLDER"` + ShareFolder string `yaml:"share_folder" env:"STORAGE_USERS_OCIS_SHARE_FOLDER" desc:"Name of the folder jailing all shares."` } type S3NGDriver struct { // Root is the absolute path to the location of the data - Root string `yaml:"root" env:"STORAGE_USERS_S3NG_ROOT"` - UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_S3NG_USER_LAYOUT"` - PermissionsEndpoint string `yaml:"permissions_endpoint" env:"STORAGE_USERS_PERMISSION_ENDPOINT;STORAGE_USERS_S3NG_PERMISSIONS_ENDPOINT"` - Region string `yaml:"region" env:"STORAGE_USERS_S3NG_REGION"` - AccessKey string `yaml:"access_key" env:"STORAGE_USERS_S3NG_ACCESS_KEY"` - SecretKey string `yaml:"secret_key" env:"STORAGE_USERS_S3NG_SECRET_KEY"` - Endpoint string `yaml:"endpoint" env:"STORAGE_USERS_S3NG_ENDPOINT"` - Bucket string `yaml:"bucket" env:"STORAGE_USERS_S3NG_BUCKET"` + Root string `yaml:"root" env:"STORAGE_USERS_S3NG_ROOT" desc:"Path for the persistence directory."` + UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_S3NG_USER_LAYOUT" desc:"Template string for the user storage layout in the persistence directory."` + PermissionsEndpoint string `yaml:"permissions_endpoint" env:"STORAGE_USERS_PERMISSION_ENDPOINT;STORAGE_USERS_S3NG_PERMISSIONS_ENDPOINT" desc:"Endpoint of the permissions service."` + Region string `yaml:"region" env:"STORAGE_USERS_S3NG_REGION" desc:"Region of the S3 bucket."` + AccessKey string `yaml:"access_key" env:"STORAGE_USERS_S3NG_ACCESS_KEY" desc:"Access key for the S3 bucket."` + SecretKey string `yaml:"secret_key" env:"STORAGE_USERS_S3NG_SECRET_KEY" desc:"Secret key for the S3 bucket."` + Endpoint string `yaml:"endpoint" env:"STORAGE_USERS_S3NG_ENDPOINT" desc:"Endpoint for the S3 bucket."` + Bucket string `yaml:"bucket" env:"STORAGE_USERS_S3NG_BUCKET" desc:"Name of the S3 bucket."` // PersonalSpaceAliasTemplate contains the template used to construct // the personal space alias, eg: `"{{.SpaceType}}/{{.User.Username | lower}}"` - PersonalSpaceAliasTemplate string `yaml:"personalspacealias_template" env:"STORAGE_USERS_S3NG_PERSONAL_SPACE_ALIAS_TEMPLATE"` + PersonalSpaceAliasTemplate string `yaml:"personalspacealias_template" env:"STORAGE_USERS_S3NG_PERSONAL_SPACE_ALIAS_TEMPLATE" desc:"Template string to construct personal space aliases."` // GeneralSpaceAliasTemplate contains the template used to construct // the general space alias, eg: `{{.SpaceType}}/{{.SpaceName | replace " " "-" | lower}}` - GeneralSpaceAliasTemplate string `yaml:"generalspacealias_template" env:"STORAGE_USERS_S3NG_GENERAL_SPACE_ALIAS_TEMPLATE"` + GeneralSpaceAliasTemplate string `yaml:"generalspacealias_template" env:"STORAGE_USERS_S3NG_GENERAL_SPACE_ALIAS_TEMPLATE" desc:"Template string to construct general space aliases."` //ShareFolder defines the name of the folder jailing all shares - ShareFolder string `yaml:"share_folder" env:"STORAGE_USERS_S3NG_SHARE_FOLDER"` + ShareFolder string `yaml:"share_folder" env:"STORAGE_USERS_S3NG_SHARE_FOLDER" desc:"Name of the folder jailing all shares."` } type OwnCloudSQLDriver struct { // Root is the absolute path to the location of the data - Root string `yaml:"root" env:"STORAGE_USERS_OWNCLOUDSQL_DATADIR"` + Root string `yaml:"root" env:"STORAGE_USERS_OWNCLOUDSQL_DATADIR" desc:"Path for the persistence directory."` //ShareFolder defines the name of the folder jailing all shares - ShareFolder string `yaml:"share_folder" env:"STORAGE_USERS_OWNCLOUDSQL_SHARE_FOLDER"` + ShareFolder string `yaml:"share_folder" env:"STORAGE_USERS_OWNCLOUDSQL_SHARE_FOLDER" desc:"name of the folder jailing all shares."` UserLayout string `yaml:"user_layout" env:"STORAGE_USERS_OWNCLOUDSQL_LAYOUT" desc:"path layout to use to navigate into a users folder in an owncloud data dir"` - UploadInfoDir string `yaml:"upload_info_dir" env:"STORAGE_USERS_OWNCLOUDSQL_UPLOADINFO_DIR"` - DBUsername string `yaml:"db_username" env:"STORAGE_USERS_OWNCLOUDSQL_DB_USERNAME"` - DBPassword string `yaml:"db_password" env:"STORAGE_USERS_OWNCLOUDSQL_DB_PASSWORD"` - DBHost string `yaml:"db_host" env:"STORAGE_USERS_OWNCLOUDSQL_DB_HOST"` - DBPort int `yaml:"db_port" env:"STORAGE_USERS_OWNCLOUDSQL_DB_PORT"` - DBName string `yaml:"db_name" env:"STORAGE_USERS_OWNCLOUDSQL_DB_NAME"` - UsersProviderEndpoint string `yaml:"users_provider_endpoint" env:"STORAGE_USERS_OWNCLOUDSQL_USERS_PROVIDER_ENDPOINT"` + UploadInfoDir string `yaml:"upload_info_dir" env:"STORAGE_USERS_OWNCLOUDSQL_UPLOADINFO_DIR" desc:"Path to a directory, where uploads will be stored temporarily."` + DBUsername string `yaml:"db_username" env:"STORAGE_USERS_OWNCLOUDSQL_DB_USERNAME" desc:"Username for the database."` + DBPassword string `yaml:"db_password" env:"STORAGE_USERS_OWNCLOUDSQL_DB_PASSWORD" desc:"Password for the database."` + DBHost string `yaml:"db_host" env:"STORAGE_USERS_OWNCLOUDSQL_DB_HOST" desc:"Hostname or IP of the database server."` + DBPort int `yaml:"db_port" env:"STORAGE_USERS_OWNCLOUDSQL_DB_PORT" desc:"Port that the database server is listening on."` + DBName string `yaml:"db_name" env:"STORAGE_USERS_OWNCLOUDSQL_DB_NAME" desc:"Name of the database to be used."` + UsersProviderEndpoint string `yaml:"users_provider_endpoint" env:"STORAGE_USERS_OWNCLOUDSQL_USERS_PROVIDER_ENDPOINT" desc:"Endpoint of the users provider."` } type Events struct { diff --git a/services/storage-users/pkg/config/defaults/defaultconfig.go b/services/storage-users/pkg/config/defaults/defaultconfig.go index ee7dd2d084..be958a5360 100644 --- a/services/storage-users/pkg/config/defaults/defaultconfig.go +++ b/services/storage-users/pkg/config/defaults/defaultconfig.go @@ -39,7 +39,6 @@ func DefaultConfig() *config.Config { Reva: &config.Reva{ Address: "127.0.0.1:9142", }, - TempFolder: filepath.Join(defaults.BaseDataPath(), "tmp", "users"), DataServerURL: "http://localhost:9158/data", MountID: "1284d238-aa92-42ce-bdc4-0b0000009157", Driver: "ocis", diff --git a/services/storage-users/pkg/revaconfig/config.go b/services/storage-users/pkg/revaconfig/config.go index fb3efbeafd..21ce7f2e73 100644 --- a/services/storage-users/pkg/revaconfig/config.go +++ b/services/storage-users/pkg/revaconfig/config.go @@ -29,7 +29,6 @@ func StorageUsersConfigFromStruct(cfg *config.Config) map[string]interface{} { "mount_id": cfg.MountID, "expose_data_server": cfg.ExposeDataServer, "data_server_url": cfg.DataServerURL, - "tmp_folder": cfg.TempFolder, }, }, "interceptors": map[string]interface{}{ @@ -50,9 +49,6 @@ func StorageUsersConfigFromStruct(cfg *config.Config) map[string]interface{} { "prefix": cfg.HTTP.Prefix, "driver": cfg.Driver, "drivers": UserDrivers(cfg), - "timeout": 86400, - "insecure": cfg.DataProviderInsecure, - "disable_tus": false, "nats_address": cfg.Events.Addr, "nats_clusterID": cfg.Events.ClusterID, }, diff --git a/services/store/pkg/config/config.go b/services/store/pkg/config/config.go index 8b76e455a6..3024daff2f 100644 --- a/services/store/pkg/config/config.go +++ b/services/store/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { GRPC GRPC `yaml:"grpc"` - Datapath string `yaml:"data_path" env:"STORE_DATA_PATH"` + Datapath string `yaml:"data_path" env:"STORE_DATA_PATH" desc:"Path for the store persistence directory."` Context context.Context `yaml:"-"` } diff --git a/services/store/pkg/config/grpc.go b/services/store/pkg/config/grpc.go index 79abc6b268..1d145619fc 100644 --- a/services/store/pkg/config/grpc.go +++ b/services/store/pkg/config/grpc.go @@ -2,6 +2,6 @@ package config // GRPC defines the available grpc configuration. type GRPC struct { - Addr string `yaml:"addr" env:"STORE_GRPC_ADDR"` + Addr string `yaml:"addr" env:"STORE_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` } diff --git a/services/thumbnails/pkg/config/http.go b/services/thumbnails/pkg/config/http.go index 05e76c9df4..d01215550d 100644 --- a/services/thumbnails/pkg/config/http.go +++ b/services/thumbnails/pkg/config/http.go @@ -2,7 +2,7 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"THUMBNAILS_HTTP_ADDR" desc:"The address of the HTTP service."` - Root string `yaml:"root" env:"THUMBNAILS_HTTP_ROOT" desc:"The root path of the HTTP service."` + Addr string `yaml:"addr" env:"THUMBNAILS_HTTP_ADDR" desc:"The bind address of the HTTP service."` + Root string `yaml:"root" env:"THUMBNAILS_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` Namespace string `yaml:"-"` } diff --git a/services/users/pkg/config/config.go b/services/users/pkg/config/config.go index 5ab003e436..7668a5e798 100644 --- a/services/users/pkg/config/config.go +++ b/services/users/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { TokenManager *TokenManager `yaml:"token_manager"` Reva *Reva `yaml:"reva"` - SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"USERS_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the encoding of the user's groupmember ships in the reva access token. To reduces token size, especially when users are members of a large number of groups."` + SkipUserGroupsInToken bool `yaml:"skip_user_groups_in_token" env:"USERS_SKIP_USER_GROUPS_IN_TOKEN" desc:"Disables the loading of user's group memberships from the reva access token."` Driver string `yaml:"driver" env:"USERS_DRIVER" desc:"The user driver which should be used by the users service. Defaults to 'ldap', can be 'owncloudsql', 'json' or 'rest'"` Drivers Drivers `yaml:"drivers"` @@ -52,7 +52,7 @@ type Debug struct { } type GRPCConfig struct { - Addr string `yaml:"addr" env:"USERS_GRPC_ADDR" desc:"The address of the grpc service."` + Addr string `yaml:"addr" env:"USERS_GRPC_ADDR" desc:"The bind address of the GRPC service."` Namespace string `yaml:"-"` Protocol string `yaml:"protocol" env:"USERS_GRPC_PROTOCOL" desc:"The transport protocol of the grpc service."` } diff --git a/services/web/pkg/config/config.go b/services/web/pkg/config/config.go index 8f018920e0..cf12fe65d3 100644 --- a/services/web/pkg/config/config.go +++ b/services/web/pkg/config/config.go @@ -19,7 +19,7 @@ type Config struct { HTTP HTTP `yaml:"http"` Asset Asset `yaml:"asset"` - File string `yaml:"file" env:"WEB_UI_CONFIG"` // TODO: rename this to a more self explaining string + File string `yaml:"file" env:"WEB_UI_CONFIG" desc:"Read the ownCloud Web configuration from this file."` // TODO: rename this to a more self explaining string Web Web `yaml:"web"` Context context.Context `yaml:"-"` @@ -27,15 +27,14 @@ type Config struct { // Asset defines the available asset configuration. type Asset struct { - Path string `yaml:"path" env:"WEB_ASSET_PATH"` + Path string `yaml:"path" env:"WEB_ASSET_PATH" desc:"Serve ownCloud Web assets from a path on the filesystem instead of the builtin assets."` } // WebConfig defines the available web configuration for a dynamically rendered config.json. type WebConfig struct { - Server string `json:"server,omitempty" yaml:"server" env:"OCIS_URL;WEB_UI_CONFIG_SERVER"` - Theme string `json:"theme,omitempty" yaml:"theme" env:""` - Version string `json:"version,omitempty" yaml:"version" env:"WEB_UI_CONFIG_VERSION"` - OpenIDConnect OIDC `json:"openIdConnect,omitempty" yaml:"oids"` + Server string `json:"server,omitempty" yaml:"server" env:"OCIS_URL;WEB_UI_CONFIG_SERVER" desc:"URL, where the oCIS APIs are reachable for ownCloud Web."` + Theme string `json:"theme,omitempty" yaml:"-"` + OpenIDConnect OIDC `json:"openIdConnect,omitempty" yaml:"oidc"` Apps []string `json:"apps" yaml:"apps"` ExternalApps []ExternalApp `json:"external_apps,omitempty" yaml:"external_apps"` Options map[string]interface{} `json:"options,omitempty" yaml:"options"` @@ -43,11 +42,11 @@ type WebConfig struct { // OIDC defines the available oidc configuration type OIDC struct { - MetadataURL string `json:"metadata_url,omitempty" yaml:"metadata_url" env:"WEB_OIDC_METADATA_URL"` + MetadataURL string `json:"metadata_url,omitempty" yaml:"metadata_url" env:"WEB_OIDC_METADATA_URL" desc:"URL for the OIDC well-known configuration endpoint. Defaults to the oCIS API URL + \"/.well-known/openid-configuration\"."` Authority string `json:"authority,omitempty" yaml:"authority" env:"OCIS_URL;OCIS_OIDC_ISSUER;WEB_OIDC_AUTHORITY" desc:"URL of the OIDC issuer. It defaults to URL of the builtin IDP."` - ClientID string `json:"client_id,omitempty" yaml:"client_id" env:"WEB_OIDC_CLIENT_ID"` - ResponseType string `json:"response_type,omitempty" yaml:"response_type" env:"WEB_OIDC_RESPONSE_TYPE"` - Scope string `json:"scope,omitempty" yaml:"scope" env:"WEB_OIDC_SCOPE"` + ClientID string `json:"client_id,omitempty" yaml:"client_id" env:"WEB_OIDC_CLIENT_ID" desc:"OIDC client ID, which ownCloud Web uses. This client needs to be set up in your IDP."` + ResponseType string `json:"response_type,omitempty" yaml:"response_type" env:"WEB_OIDC_RESPONSE_TYPE" desc:"OIDC response type to use for authentication."` + Scope string `json:"scope,omitempty" yaml:"scope" env:"WEB_OIDC_SCOPE" desc:"OIDC scopes to request during authentication."` } // ExternalApp defines an external web app. @@ -72,8 +71,8 @@ type ExternalAppConfig struct { // Web defines the available web configuration. type Web struct { - Path string `yaml:"path" env:"WEB_UI_PATH"` - ThemeServer string `yaml:"theme_server" env:"OCIS_URL;WEB_UI_THEME_SERVER"` // used to build Theme in WebConfig - ThemePath string `yaml:"theme_path" env:"WEB_UI_THEME_PATH"` // used to build Theme in WebConfig + Path string `yaml:"path" env:"WEB_UI_PATH" desc:"Read the ownCloud Web configuration from this file path."` + ThemeServer string `yaml:"theme_server" env:"OCIS_URL;WEB_UI_THEME_SERVER" desc:"URL to load themes from. Will be prepended to the theme path."` // used to build Theme in WebConfig + ThemePath string `yaml:"theme_path" env:"WEB_UI_THEME_PATH" desc:"URL path to load themes from. The theme server will be prepended."` // used to build Theme in WebConfig Config WebConfig `yaml:"config"` } diff --git a/services/web/pkg/config/defaults/defaultconfig.go b/services/web/pkg/config/defaults/defaultconfig.go index e1f09a6928..48584ec78f 100644 --- a/services/web/pkg/config/defaults/defaultconfig.go +++ b/services/web/pkg/config/defaults/defaultconfig.go @@ -38,9 +38,8 @@ func DefaultConfig() *config.Config { ThemeServer: "https://localhost:9200", ThemePath: "/themes/owncloud/theme.json", Config: config.WebConfig{ - Server: "https://localhost:9200", - Theme: "", - Version: "0.1.0", + Server: "https://localhost:9200", + Theme: "", OpenIDConnect: config.OIDC{ MetadataURL: "", Authority: "https://localhost:9200", diff --git a/services/web/pkg/config/http.go b/services/web/pkg/config/http.go index 4d2c76d93c..addb0fce0c 100644 --- a/services/web/pkg/config/http.go +++ b/services/web/pkg/config/http.go @@ -2,8 +2,8 @@ package config // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"WEB_HTTP_ADDR"` + Addr string `yaml:"addr" env:"WEB_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` - Root string `yaml:"root" env:"WEB_HTTP_ROOT"` - CacheTTL int `yaml:"cache_ttl" env:"WEB_CACHE_TTL"` + Root string `yaml:"root" env:"WEB_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` + CacheTTL int `yaml:"cache_ttl" env:"WEB_CACHE_TTL" desc:"Cache policy in seconds for ownCloud Web assets."` } diff --git a/services/webdav/pkg/config/config.go b/services/webdav/pkg/config/config.go index 843d25138e..2e609335a0 100644 --- a/services/webdav/pkg/config/config.go +++ b/services/webdav/pkg/config/config.go @@ -18,7 +18,7 @@ type Config struct { HTTP HTTP `yaml:"http"` - OcisPublicURL string `yaml:"ocis_public_url" env:"OCIS_URL;OCIS_PUBLIC_URL"` + OcisPublicURL string `yaml:"ocis_public_url" env:"OCIS_URL;OCIS_PUBLIC_URL" desc:"URL, where oCIS is reachable for users."` WebdavNamespace string `yaml:"webdav_namespace" env:"WEBDAV_WEBDAV_NAMESPACE" desc:"CS3 path layout to use when forwarding /webdav requests"` RevaGateway string `yaml:"reva_gateway" env:"REVA_GATEWAY" desc:"The CS3 gateway endpoint."` diff --git a/services/webdav/pkg/config/http.go b/services/webdav/pkg/config/http.go index 8417b2f3a6..c6c25c06d8 100644 --- a/services/webdav/pkg/config/http.go +++ b/services/webdav/pkg/config/http.go @@ -10,8 +10,8 @@ type CORS struct { // HTTP defines the available http configuration. type HTTP struct { - Addr string `yaml:"addr" env:"WEBDAV_HTTP_ADDR" desc:"The HTTP API address."` + Addr string `yaml:"addr" env:"WEBDAV_HTTP_ADDR" desc:"The bind address of the HTTP service."` Namespace string `yaml:"-"` - Root string `yaml:"root" env:"WEBDAV_HTTP_ROOT" desc:"The HTTP API root path."` + Root string `yaml:"root" env:"WEBDAV_HTTP_ROOT" desc:"Subdirectory that serves as the root for this HTTP service."` CORS CORS `yaml:"cors"` }