Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> Start hosting your website from home.

This isn't feasible for a large chunk of the population, mainly because ISPs like Comcast love to give you 500 mbps down while limiting your upload to a pitiful 10 mbps.

Host a single 100K image that hits the front page of reddit and your home internet gets hugged to death.



How many 100k image hits do you get on your personal website you made for fun? In the entire 20 years I've hosted my website on my comcast connection I have never had this issue. If you're going to post an image to reddit (which is kind of going backwards from the point of all this) then just mirror it onto some popular image host (or your VPS). This doesn't prevent you from also serving up a copy from your local disk to visitors.

1 megabit of upstream is plenty for a personal website. I can say this from long experience.


when comes time for your personal websites 15 minutes of fame it becomes inaccessible due to severe upstream bottlenecking


If that 15 minutes of fame is so important, put up a load balancer with autoscaling or make sure the Wayback machine archives every post upon publication.

Not every site needs to have 3+ nines of uptime.


While yes, that would work, we were talking about hosting things yourself at home.


Obviously, if I'm going to share the image, I won't link it directly and would use an image hosting service, or just upload it directly to reddit for them to host.

That does nothing if some other rando decides to link to it.


Put it behind cloudflare, problem solved.


Even better, you can store images on B2 for just 5 USD/month/terabyte and front it with Cloudflare for free traffic. https://help.backblaze.com/hc/en-us/articles/217666928-Using... https://help.backblaze.com/hc/en-us/articles/360010017893-Ho...

You can host your HTML/JS/CSS on Github Pages fronted by Cloudflare again for free.

For dynamic stuff, I just set up an ElasticSearch cluster with three VPSes from https://php-friends.de/vserver-ssd/vserver-schnupperspecial-... for the grand total of 10EUR/month... these are some serious hardware for 4 EUR (inc German VAT): dedicated two dedicated Haswell or Broadwell cores, 6GB RAM, 65GB SSD. Slap Ubuntu on them, then https://help.ubuntu.com/lts/serverguide/automatic-updates.ht... and https://www.cyberciti.biz/faq/howto-live-patch-ubuntu-linux-... will keep your server secure.


Then you aren't hosting your own website from home anymore.


IPFS solves this. You only need to host an index of the content, plus the "seed" copy, for anyone else to download and mirror as they please.


It solves it so long as you are happy to upload several gigabytes a day seeding nothing just to keep up with DHT chatter:

https://github.com/ipfs/go-ipfs/issues/3429


I'm guessing this is being downvoted because after all, for unpopular stuff, you're still going to be the one hosting your content.


If it is unpopular, then the resources required to host the content are manageable.

If it is popular, the IPFS users seed it to each other so your load is still manageable.


Good point!


But wouldn't it solve the problem of your server exploding during your sites 15 minutes of fame? So many users at once could use the P2P of IPFS and take load off the server.


A pitiful 10mbps, eh?

Back in my day...

That's your 100K image 10 times a second, or 600 times a minute.

You could also just like, run a caching server on a 5$ VPS.


Right, but then you wouldn't be hosting it at home anymore, which is what we were talking about.


The only difference is that your final SSL termination would occur on a host that's better placed to handle the load. Literally everything else could be done on-prem e.g. at home.

Realistically this 'oh no I got hammered by HN' case is something that is irrelevant anyway. If you're really worried about it, don't host large image files, sorted. The "old internet" didn't have that stuff anyway because we were all on slow connections, 100KB took 10+ seconds to load on dialup.


Any way around this? Surely i don't need an industrial setup to scale my home website


You don't, the reality is it's extremely unlikely this happens and if it does the worst outcome is high bandwidth use + the image doesn't load for everyone. Hardly the end of the world.

You can very easily host things on a paid server though, which these days cost very little, use another image host or S3/similar when if things went crazy popular.


> worst outcome is high bandwidth use + the image doesn't load for everyone. Hardly the end of the world.

No, the worst outcome is that your home internet connection is being effectively DDoSed.

You could probably apply some QoS on your router to minimize the effect, of course.


Free Cloudflare account


As I'm mentioning in other comments, then you wouldn't be hosting from home.


I think most isps also block outgoing traffic on port 80 these days. At least, that's the issue me and some friends found when we tried to host websites on our various ISPs.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: