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

OCM cannot open shared file #10358

Closed
wkloucek opened this issue Oct 21, 2024 · 3 comments · Fixed by #10440
Closed

OCM cannot open shared file #10358

wkloucek opened this issue Oct 21, 2024 · 3 comments · Fixed by #10440
Assignees
Labels
Priority:p2-high Escalation, on top of current planning, release blocker Type:Bug

Comments

@wkloucek
Copy link
Contributor

Describe the bug

When I share a file using OCM, I cannot open it as the share receiver.

Steps to reproduce

  1. use the OCM deployment example from Add OCM support ocis-charts#701
  2. share a text file from oCIS 1 to oCIS 2
  3. open the text file as share receiver

Expected behavior

The text file can be opened and edited.

Actual behavior

https://ocis.kube.owncloud.test/remote.php/dav/spaces/89f37a33-858b-45fa-8890-a1f2b27d90e1%24c04eee26-d9b9-4238-9b51-4aeb3b9f330b!Lw%3D%3D fails with HTTP 500

proxy-65d7c5746f-qp4nj proxy {"level":"error","service":"proxy","error":"failed to verify access token: token is malformed: token contains an invalid number of segments","authenticator":"oidc","path":"/dav/ocm/5caffad9-acff-480b-a370-5e3c1e0e87cb/","user_agent":"Go-http-client/1.1","client.address":"10.244.0.1","network.peer.address":"","network.peer.port":"","time":"2024-10-21T09:37:47Z","message":"failed to authenticate the request"}
proxy-65d7c5746f-qp4nj proxy {"level":"error","service":"proxy","error":"failed to verify access token: token is malformed: token contains an invalid number of segments","authenticator":"oidc","path":"/dav/ocm/5caffad9-acff-480b-a370-5e3c1e0e87cb/","user_agent":"Go-http-client/1.1","client.address":"10.244.0.1","network.peer.address":"","network.peer.port":"","time":"2024-10-21T09:37:47Z","message":"failed to authenticate the request"}

Setup

oCIS 6.5 deployed with owncloud/ocis-charts#701

Additional context

@micbar micbar added the Priority:p2-high Escalation, on top of current planning, release blocker label Oct 21, 2024
@micbar micbar moved this from Qualification to Prio 2 in Infinite Scale Team Board Oct 21, 2024
@rhafer rhafer self-assigned this Oct 24, 2024
@rhafer rhafer moved this from Prio 2 to In progress in Infinite Scale Team Board Oct 24, 2024
@rhafer
Copy link
Contributor

rhafer commented Oct 28, 2024

I've been able to reproduce the problem using the above referenced ocis-charts PR. I am still trying to figure out what exactly is wrong because it works just fine for me in a manually created docker setup.

@rhafer
Copy link
Contributor

rhafer commented Oct 29, 2024

Argh: https://github.com/owncloud/ocis/blob/master/services/ocm/pkg/revaconfig/config.go#L166

We're setting the data_server_url for the ocm storageprovider is set to the listen address of the http endpoint. Which in case of a helm deployment is 0.0.0.0:9280. That can't work as a download url.

To fix we need to introduce a data_server_url setting similar to what we have already for the other storage providers.

@rhafer
Copy link
Contributor

rhafer commented Oct 29, 2024

The above reference PR should fix the issue.

@wkloucek This requires setting OCM_OCM_STORAGE_DATA_SERVER_URL in the ocm helm deployment obivously. (See e.g. storage-users)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:p2-high Escalation, on top of current planning, release blocker Type:Bug
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

3 participants