Open phil-davis opened 4 years ago
When I do similar actions locally in Phoenix, I get:
And the OCIS server has:
2020-09-08T14:36:00+05:45 ERR Error fetching from accounts-service error="{\"id\":\"go.micro.client\",\"code\":500,\"detail\":\"service com.owncloud.api.accounts: not found\",\"status\":\"Internal Server Error\"}" query="id eq 'f7fbf8c8-139b-4376-b307-cf0a8c2d0d9c'" service=proxy
2020-09-08T14:36:01+05:45 INF unary code=OK end="08/Sep/2020:14:36:01 +0545" from=tcp://127.0.0.1:55760 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=97523 traceid=22de6a3f78a38d539e76ba8b74a7dfba uri=/cs3.storage.registry.v1beta1.RegistryAPI/GetStorageProvider user-agent=grpc-go/1.26.0
2020-09-08T14:36:01+05:45 INF unary code=OK end="08/Sep/2020:14:36:01 +0545" from=tcp://127.0.0.1:49038 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=195137 traceid=22de6a3f78a38d539e76ba8b74a7dfba uri=/cs3.storage.provider.v1beta1.ProviderAPI/CreateHome user-agent=grpc-go/1.26.0
2020-09-08T14:36:01+05:45 INF unary code=OK end="08/Sep/2020:14:36:01 +0545" from=tcp://127.0.0.1:55628 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=941759 traceid=22de6a3f78a38d539e76ba8b74a7dfba uri=/cs3.gateway.v1beta1.GatewayAPI/CreateHome user-agent=grpc-go/1.26.0
2020-09-08T14:36:01+05:45 INF access token is already provided pkg=rhttp service=reva traceid=3a6bf665dbdb24857ea0ef927eb07a2e
2020-09-08T14:36:01+05:45 INF unary code=OK end="08/Sep/2020:14:36:01 +0545" from=tcp://127.0.0.1:55760 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=99492 traceid=3a6bf665dbdb24857ea0ef927eb07a2e uri=/cs3.storage.registry.v1beta1.RegistryAPI/GetStorageProvider user-agent=grpc-go/1.26.0
2020-09-08T14:36:01+05:45 INF unary code=OK end="08/Sep/2020:14:36:01 +0545" from=tcp://127.0.0.1:49038 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=662701 traceid=3a6bf665dbdb24857ea0ef927eb07a2e uri=/cs3.storage.provider.v1beta1.ProviderAPI/Stat user-agent=grpc-go/1.26.0
2020-09-08T14:36:01+05:45 INF unary code=OK end="08/Sep/2020:14:36:01 +0545" from=tcp://127.0.0.1:55760 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=72400 traceid=3a6bf665dbdb24857ea0ef927eb07a2e uri=/cs3.storage.registry.v1beta1.RegistryAPI/GetStorageProvider user-agent=grpc-go/1.26.0
2020-09-08T14:36:03+05:45 INF unary code=OK end="08/Sep/2020:14:36:03 +0545" from=tcp://127.0.0.1:37766 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=1959581380 traceid=3a6bf665dbdb24857ea0ef927eb07a2e uri=/cs3.identity.user.v1beta1.UserAPI/GetUser user-agent=grpc-go/1.26.0
2020-09-08T14:36:03+05:45 INF unary code=OK end="08/Sep/2020:14:36:03 +0545" from=tcp://127.0.0.1:49038 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=1960752785 traceid=3a6bf665dbdb24857ea0ef927eb07a2e uri=/cs3.storage.provider.v1beta1.ProviderAPI/Stat user-agent=grpc-go/1.26.0
2020-09-08T14:36:03+05:45 INF unary code=OK end="08/Sep/2020:14:36:03 +0545" from=tcp://127.0.0.1:55748 pkg=rgrpc service=reva start="08/Sep/2020:14:36:01 +0545" time_ns=1962731188 traceid=3a6bf665dbdb24857ea0ef927eb07a2e uri=/cs3.gateway.v1beta1.GatewayAPI/Stat user-agent=grpc-go/1.26.0
2020-09-08T14:36:03+05:45 ERR gateway: error downloading error="error: permission denied: gateway: cannot download share folder or share name: path=/home/Shares/text.txt" pkg=rgrpc service=reva traceid=3a6bf665dbdb24857ea0ef927eb07a2e
Maybe the accounts service goes down? And then there is no way to sort out the permissions...?
This might have a common solution to #205
Fixing this should get at least some scenarios passing in https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareManagement/acceptSharesToSharesFolder.feature
the problem is that the reva gateway logic was built with folder shares only in mind. It would check if an up / download was targeted at a direct child of a users "/Shares" folder and would immediately deny the request. https://github.com/cs3org/reva/pull/1170 should allow that for files.
This scenario is failing: https://github.com/owncloud/core/blob/master/tests/acceptance/features/apiShareManagement/acceptSharesToSharesFolder.feature#L15
https://cloud.drone.io/owncloud/ocis/1488/4/7
See #207 for a different issue - when the share is accepted the share does get created but the response body is empty.
In this issue, the test scenario accepts the share and does not bother to check the response body. It tries to download the received shared file. The download seems to "work" but the file content does not actually come - it seems empty.