Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/user settings capability #2655

Merged
merged 3 commits into from
Oct 21, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions changelog/unreleased/add-user-setting-capability.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Enhancement: Add user setting capability

We've added a capability to communicate the existance of a user settings service to clients.

https://github.com/owncloud/ocis/pull/2655
https://github.com/owncloud/web/issues/5926
4 changes: 2 additions & 2 deletions changelog/unreleased/buf-tooling.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Bugfix: Enhancement
Enhancement: Broaden bufbuild/Buf usage
pascalwengerter marked this conversation as resolved.
Show resolved Hide resolved

We've switched the usage of bufbuild/Buf from a protoc replacement only to
also using it to configuring the outputs and pinning dependencies.
also using it to confige the outputs and pinning dependencies.

https://github.com/owncloud/ocis/pull/2630
https://github.com/owncloud/ocis/pull/2616
2 changes: 1 addition & 1 deletion changelog/unreleased/create-space-quota.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Change: Configurable default quota

When creating a new space a (configurable) default quota will be used (instead the hardcoded one)
When creating a new space a (configurable) default quota will be used (instead the hardcoded one).
One can set the EnvVar `GRAPH_SPACES_DEFAULT_QUOTA` to configure it

https://github.com/owncloud/ocis/issues/2621
Expand Down
5 changes: 3 additions & 2 deletions changelog/unreleased/go-embed-instead-fileb0x.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
Enhancement: use go-embed insted of fileb0x
Enhancement: Replace fileb0x with go-embed

go-embed delivers already the funtionality we need but with less code. We decided to use it instead of 3rd party fileb0x
go-embed already brings the functionality we need but with less code. We decided to use it instead of 3rd party fileb0x

https://github.com/owncloud/ocis/issues/1199
https://github.com/owncloud/ocis/pull/2631
https://github.com/owncloud/ocis/pull/2649
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ require (
github.com/blevesearch/bleve/v2 v2.2.1
github.com/coreos/go-oidc/v3 v3.1.0
github.com/cs3org/go-cs3apis v0.0.0-20211018122138-391b29bd7803
github.com/cs3org/reva v1.14.1-0.20211021070229-852282ce34f5
github.com/cs3org/reva v1.14.1-0.20211021110426-87c920ffc25f
github.com/disintegration/imaging v1.6.2
github.com/glauth/glauth/v2 v2.0.0-20211021011345-ef3151c28733
github.com/go-chi/chi/v5 v5.0.4
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -305,8 +305,8 @@ github.com/crewjam/saml v0.4.5/go.mod h1:qCJQpUtZte9R1ZjUBcW8qtCNlinbO363ooNl02S
github.com/cs3org/cato v0.0.0-20200828125504-e418fc54dd5e/go.mod h1:XJEZ3/EQuI3BXTp/6DUzFr850vlxq11I6satRtz0YQ4=
github.com/cs3org/go-cs3apis v0.0.0-20211018122138-391b29bd7803 h1:R/6llgTNKxQQ7GaSTgFn6Fp8N50wIlagmdR7WY5LntM=
github.com/cs3org/go-cs3apis v0.0.0-20211018122138-391b29bd7803/go.mod h1:UXha4TguuB52H14EMoSsCqDj7k8a/t7g4gVP+bgY5LY=
github.com/cs3org/reva v1.14.1-0.20211021070229-852282ce34f5 h1:mGWW3ACgRp4iLOjUx6OiOX16j2SFUIM3DcWqzFs8KJQ=
github.com/cs3org/reva v1.14.1-0.20211021070229-852282ce34f5/go.mod h1:wkZXgaxq5nO6Dvl9qRpHpbGUQrWyTfwqWtBqOiCWy+k=
github.com/cs3org/reva v1.14.1-0.20211021110426-87c920ffc25f h1:eTNBGvvU6r6OhnL/3M8QxdCp3yHgklhfMHktOa111BY=
github.com/cs3org/reva v1.14.1-0.20211021110426-87c920ffc25f/go.mod h1:wkZXgaxq5nO6Dvl9qRpHpbGUQrWyTfwqWtBqOiCWy+k=
github.com/cubewise-code/go-mime v0.0.0-20200519001935-8c5762b177d8 h1:Z9lwXumT5ACSmJ7WGnFl+OMLLjpz5uR2fyz7dC255FI=
github.com/cubewise-code/go-mime v0.0.0-20200519001935-8c5762b177d8/go.mod h1:4abs/jPXcmJzYoYGF91JF9Uq9s/KL5n1jvFDix8KcqY=
github.com/cyberdelia/templates v0.0.0-20141128023046-ca7fffd4298c/go.mod h1:GyV+0YP4qX0UQ7r2MoYZ+AvYDp12OF5yg4q8rGnyNh4=
Expand Down
6 changes: 6 additions & 0 deletions storage/pkg/command/frontend.go
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,12 @@ func frontendConfigFromStruct(c *cli.Context, cfg *config.Config, filesCfg map[s
"user": map[string]interface{}{
"send_mail": true,
"profile_picture": false,
"settings": []map[string]interface{}{
{
"enabled": true,
"version": "1.0.0",
},
},
Comment on lines +275 to +280
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's just the oCIS side of capabilities. It is only used to configure REVA. Therefore to actually have it available on the endpoint you also need to add this to REVA. You can see in this PR how do that: https://github.com/cs3org/reva/pull/2088/files

Currently curl -k 'https://localhost:9200/ocs/v1.php/cloud/capabilities?format=json' -u einstein:relativity | jq . does only give me:

          "user": {
            "send_mail": true,
            "profile_picture": false
          }

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay interesting, I thought we're wrapping/extending REVA's capabilities in oCIS...will add a PR there then, too

},
"user_enumeration": map[string]interface{}{
"enabled": true,
Expand Down