Skip to content

Commit

Permalink
Add example
Browse files Browse the repository at this point in the history
  • Loading branch information
ishank011 committed Jan 29, 2021
1 parent 417defd commit 5f818c6
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion changelog/unreleased/home-mapping.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@ Enhancement: Functionality to map home directory to different storage providers
We added a parameter in reva that allows us to redirect /home requests to
different storage providers based on a mapping derived from the user attributes,
which was previously not possible since we hardcode the /home path for all
users. This PR adds the config for that parameter.
users. For example, having its value as `/home/{{substr 0 1 .Username}}` can be
used to redirect home requests for different users to different storage
providers.

https://github.com/owncloud/ocis/pull/1186
https://github.com/cs3org/reva/pull/1142
2 changes: 1 addition & 1 deletion storage/pkg/flagset/gateway.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ func GatewayWithConfig(cfg *config.Config) []cli.Flag {
&cli.StringFlag{
Name: "storage-home-mapping",
Value: "",
Usage: "mapping template for user home paths to user-specific mount points",
Usage: "mapping template for user home paths to user-specific mount points, e.g. /home/{{substr 0 1 .Username}}",
EnvVars: []string{"STORAGE_GATEWAY_HOME_MAPPING"},
Destination: &cfg.Reva.Gateway.HomeMapping,
},
Expand Down

0 comments on commit 5f818c6

Please sign in to comment.