Skip to content

Commit

Permalink
Add new capability for announcing share jail
Browse files Browse the repository at this point in the history
  • Loading branch information
kulmann committed May 2, 2022
1 parent bf936c8 commit 1c5bfac
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 4 deletions.
5 changes: 5 additions & 0 deletions changelog/unreleased/spaces-capabilities.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Enhancement: Added `share_jail` and `projects` feature flags in spaces capability

We've added feature flags to the `spaces` capability to indicate to clients which features are supposed to be shown to users.

https://github.com/owncloud/ocis/pull/3626
3 changes: 2 additions & 1 deletion changelog/unreleased/update-reva.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ https://github.com/owncloud/ocis/pull/3570
https://github.com/owncloud/ocis/pull/3601
https://github.com/owncloud/ocis/pull/3605
https://github.com/owncloud/ocis/pull/3611
https://github.com/owncloud/ocis/pull/3621
https://github.com/owncloud/ocis/issues/3621
https://github.com/owncloud/ocis/pull/3637
6 changes: 4 additions & 2 deletions extensions/frontend/pkg/command/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -286,8 +286,10 @@ func frontendConfigFromStruct(c *cli.Context, cfg *config.Config, filesCfg map[s
},
},
"spaces": map[string]interface{}{
"version": "0.0.1",
"enabled": cfg.EnableProjectSpaces,
"version": "0.0.1",
"enabled": cfg.EnableProjectSpaces || cfg.EnableShareJail,
"projects": cfg.EnableProjectSpaces,
"share_jail": cfg.EnableShareJail,
},
},
"version": map[string]interface{}{
Expand Down
3 changes: 2 additions & 1 deletion extensions/frontend/pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ type Config struct {
SkipUserGroupsInToken bool `yaml:"skip_users_groups_in_token"`

EnableFavorites bool `yaml:"favorites"`
EnableProjectSpaces bool `yaml:"enable_project_spaces"`
EnableProjectSpaces bool `yaml:"enable_project_spaces" env:"FRONTEND_ENABLE_PROJECT_SPACES" desc:"Indicates to clients that project spaces are supposed to be made available."`
EnableShareJail bool `yaml:"enable_share_jail" env:"FRONTEND_ENABLE_SHARE_JAIL" desc:"Indicates to clients that the share jail is supposed to be used."`
UploadMaxChunkSize int `yaml:"upload_max_chunk_size"`
UploadHTTPMethodOverride string `yaml:"upload_http_method_override"`
DefaultUploadProtocol string `yaml:"default_upload_protocol"`
Expand Down
1 change: 1 addition & 0 deletions extensions/frontend/pkg/config/defaults/defaultconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ func DefaultConfig() *config.Config {
PublicURL: "https://localhost:9200",
EnableFavorites: false,
EnableProjectSpaces: true,
EnableShareJail: true,
UploadMaxChunkSize: 1e+8,
UploadHTTPMethodOverride: "",
DefaultUploadProtocol: "tus",
Expand Down

0 comments on commit 1c5bfac

Please sign in to comment.