-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Companion: support sending custom headers to the upload destination #4942
Comments
Hi, unfortunately this has nothing to do with Uppy. Apparently you've setup some kind of authentication on your tus server and this is not the place for help with tus servers. There is also not enough information to help you. Companion doesn't expect the tus server to have auth so I recommend removing it and seeing if it works. I know for a fact that things will work with tus-node-server and tusd |
@Murderlon |
As far as I know it's not possible to send extra headers to the upload destination from Companion, only to Companion. But I can see the value in that, with Supabase, but also for anyone who wants to send auth headers to their destination. |
Thank you, I appreciate it ! |
Just ran into this myself 😕. I utilize RLS in Supabase so I need to be able to pass the JWT token. Are there any workarounds for this? |
Contributing or forking is the only workaround for now. |
@Murderlon |
We're very light on hours from core contributors lately. Currently Google Photos support is being developed and a massive TS migration, in preparation for #4764. However since this is a small feature, I can probably take a look in the next two weeks. The quikfix would be to allow a Thoughts @mifi? Here is a client-side example from Supabase. |
Looking at the code I dont understand why the supabase client side example wouldn’t work. As far as i can see, when a Tus upload happens in companion, the Uppy Tus plugin |
Awesome, thank you! I'll definitely give it a try once it's implemented
I understand, but it seems it didn't work out for both @ikupenov and me |
I was using standalone companion in Docker if that matters. |
I just tested locally with uppyDashboard.use(Tus, { endpoint: 'http://127.0.0.1:8001', limit: 6, headers: { 'X-MyHeader': 'hello' } }) I then ran a fake Tus TCP server: nc -v -l 8001 and I uploaded a single file from google drive, and I got this on my fake Tus TCP
as you can see the header is included, so it seems to be working. Need some reproducible code or more detailed steps to reproduce if you think it's still an issue. |
Closing this because it's seemingly already implemented |
Steps to reproduce
Expected behavior
The file should be successfully uploaded to the target endpoint
http://localhost:54321/storage/v1/upload/resumable
without any authentication issues, assuming proper configuration and valid access tokens.Actual behavior
During the upload process, an error occurs indicating a failure in the authentication step. The system specifically reports a "jwt must be provided" error, suggesting that the required JWT token for authorization is missing or not properly included in the request. This results in a 400 Bad Request response from the server, halting the upload process.
details
The text was updated successfully, but these errors were encountered: