Live data from Hacker News

Uppy 1.0: Your best friend in file uploading

uppy.io

71–80 of 82 posts

Re: Uppy 1.0: Your best friend in file uploading

#71
post #2

One of the developers here. We worked three years to make Uppy the best open source file uploader the world has seen. Looking forward to your brutally honest feedback! Happy to answer questions too.

I just tried integrating this into a hobby project of mine. I like the looks of the dashboard, and direct uploads from device work fine, but I don't understand yet how to get other uploads to work.

Am I supposed to be running my own companion server, or is the server shown in the examples supposed to work for my project (I'm seeing CORS errors)?

Re: Uppy 1.0: Your best friend in file uploading

#72
post #2

One of the developers here. We worked three years to make Uppy the best open source file uploader the world has seen. Looking forward to your brutally honest feedback! Happy to answer questions too.

I just tried integrating this into a hobby project of mine. I like the looks of the dashboard, and direct uploads from device work fine, but I don't understand yet how to get other uploads to work. Am I supposed to be running my own companion server, or is the server shown in the examples supposed to work for my project (I'm seeing CORS errors)?

Thanks for taking an interest!

The Companion server used in the examples (companion.uppy.io) is really only meant for demo purposes and hence throws CORS errors if you'd try to use it for your own website.

You have three options:

1. Disable Instagram/Dropbox/Google Drive. Then you can use Uppy without any special server components (it'll just upload to your Apache server or S3 bucket)

2. Enable Instagram and friends but run Companion on your own server. It can be installed as middleware into an existing Express server, or run as a Standalone server on a different port than your webserver.

3. Use Transloadit's hosted Companion server. Requires a paid subscription (but also gets you hosted tus servers for upload handling, and our encoding platform, all of which are globally distributed)

Re: Uppy 1.0: Your best friend in file uploading

#73
post #47

Earlier quoted context omitted.

Whether or not this is possible, it seems like a serious DDOS risk. Some one with malicious intent could give you a huge hosting bill. It might be difficult to apply IP-based rate-limiting without a server.

There's two ways to directly upload to S3 buckets (or GCS): 1) You allow append-only access for the world, maybe in combination with an expiry policy. Indeed only useful for a few use cases I'd say 2) You deploy signing of requests, and you only sign for those who are logged in, or otherwise match criteria important to your app. A bit more hassle, and still requires server-side code (whether traditionally hosted or '…

>That said, I'm not sure how serious you are about handling file uploads, but uploading directly to buckets often means uploading to a single region (on aws, a bucket may be hosted in us-east-1 for instance, meaning high latency for folks in e.g. Australia). This may or may not be problematic for your use case, but it did bring us complaints when we had that.

You can use https://docs.aws.amazon.com/AmazonS3/latest/dev/transfer-acc...

S3 acceleration uses the cloudfront distributed edge locations. As the data arrives at an edge location, data is routed to Amazon S3 over an optimized network path. This costs more money though.

Re: Uppy 1.0: Your best friend in file uploading

#74
post #37
post #4

Prev. 2 days: - https://news.ycombinator.com/item?id=19756159 (same ID as prev. post by same user) - https://news.ycombinator.com/item?id=19759039 - https://news.ycombinator.com/item?id=19765780

When a story hasn't had significant attention yet, a small number of reposts is ok. This is in the FAQ: https://news.ycombinator.com/newsfaq.html .

Thanks, Dang. What qualifies as significant?

Re: Uppy 1.0: Your best friend in file uploading

#75
post #72

Earlier quoted context omitted.

I just tried integrating this into a hobby project of mine. I like the looks of the dashboard, and direct uploads from device work fine, but I don't understand yet how to get other uploads to work. Am I supposed to be running my own companion server, or is the server shown in the examples supposed to work for my project (I'm seeing CORS errors)?

Thanks for taking an interest! The Companion server used in the examples (companion.uppy.io) is really only meant for demo purposes and hence throws CORS errors if you'd try to use it for your own website. You have three options: 1. Disable Instagram/Dropbox/Google Drive. Then you can use Uppy without any special server components (it'll just upload to your Apache server or S3 bucket) 2. Enable Instagram and friends…

Thanks for confirming this! This all makes a lot of sense, but might merit clarifying in your documentation.

When I see sample code, I generally assume that I can copy and paste it onto my own site. So a comment "You can try this code on OUR site, but if you want to use it on YOURS, you need to take care of your own companion hosting" in your sample code would be helpful.

Re: Uppy 1.0: Your best friend in file uploading

#76
post #72

Earlier quoted context omitted.

Thanks for taking an interest! The Companion server used in the examples (companion.uppy.io) is really only meant for demo purposes and hence throws CORS errors if you'd try to use it for your own website. You have three options: 1. Disable Instagram/Dropbox/Google Drive. Then you can use Uppy without any special server components (it'll just upload to your Apache server or S3 bucket) 2. Enable Instagram and friends…

Thanks for confirming this! This all makes a lot of sense, but might merit clarifying in your documentation. When I see sample code, I generally assume that I can copy and paste it onto my own site. So a comment "You can try this code on OUR site, but if you want to use it on YOURS, you need to take care of your own companion hosting" in your sample code would be helpful.

It does say so in a few places but I agree it's useful right in the examples too, will pass it on to the team!

Re: Uppy 1.0: Your best friend in file uploading

#77
post #76

Earlier quoted context omitted.

Thanks for confirming this! This all makes a lot of sense, but might merit clarifying in your documentation. When I see sample code, I generally assume that I can copy and paste it onto my own site. So a comment "You can try this code on OUR site, but if you want to use it on YOURS, you need to take care of your own companion hosting" in your sample code would be helpful.

It does say so in a few places but I agree it's useful right in the examples too, will pass it on to the team!

Having read your site, I was certainly aware of all the companion options you enumerated above. However, I did not see your above sentence "companion.uppy.io is really only meant for demo purposes and hence throws CORS errors if you'd try to use it for your own website" (or anything equivalent) anywhere on the site.

I realize that this sentence (while clear, accurate, and quite reasonable) takes a bit of polish to turn into a positive message which won't scare away potential users ;-)

Alternatively, maybe you could set up your demo server to accept requests from randos for exploratory purposes, but with a quota set low enough that it won't be abused for production?

Re: Uppy 1.0: Your best friend in file uploading

#78
post #74
post #37

Earlier quoted context omitted.

When a story hasn't had significant attention yet, a small number of reposts is ok. This is in the FAQ: https://news.ycombinator.com/newsfaq.html .

Thanks, Dang. What qualifies as significant?

We purposely don't pin that down because there are always borderline cases, but if a post got, say, more than 20 points and a bunch of comments, we'd usually treat reposts as a dupe. But if a story is unusually interesting we sometimes relax that.

The restriction lasts for about a year, as the FAQ explains. Then it's ok for it to appear again.

Re: Uppy 1.0: Your best friend in file uploading

#79
post #78
post #74

Earlier quoted context omitted.

Thanks, Dang. What qualifies as significant?

We purposely don't pin that down because there are always borderline cases, but if a post got, say, more than 20 points and a bunch of comments, we'd usually treat reposts as a dupe. But if a story is unusually interesting we sometimes relax that. The restriction lasts for about a year, as the FAQ explains. Then it's ok for it to appear again.

Thanks again for your time and for explaining things.

Re: Uppy 1.0: Your best friend in file uploading

#80
post #62
post #58

Looks great, awesome job. I see there's ability to upload directly to S3, any ability to upload direct to Azure Blob store?

Sorry, no. If you really need it today, you could hook up Uppy to Transloadit, and it could export to Azure. But requires a paid subscription. I am happy to accept a PR for Uppy to enable direct Azure blob storage uploads however! (does this work with signing URLs also?)

Yes, Azure supports Shared Access Signature (SAS) tokens. [1]

I'm afraid my Javascript is rather poor but I'll happily look at what it would take to create a plugin for Azure this weekend. Presumably the S3 multi-part uploader and associated companion server would be a good base to understand the flow?

[1]: https://docs.microsoft.com/en-us/azure/storage/common/storag...

Post reply on HN