Live data from Hacker News

Self hosting in 2023

grifel.dev

251–260 of 307 posts

Re: Self hosting in 2023

#251

Self-hosting is weird. I hear a lot of people say it's so much work, but I put like an hour a month into my server at most. I think it's mostly fine from an administrative standpoint, as mentioned elsewhere, not much has actually changed from 2003. You definitely don't need kubernetes. If anything, I think most of what's changed since then is that there's been a flood of bad sysadmin advice making people believe they…

I used to keep a server in my room for a decade and I plan to retire it this year. An hour a month is actually a lot as this overhead is highly non-uniform; the server may work fine for months then need a whole day worth of work, which I can no longer easily sustain. [1] That said, I have of course run lots of softwares I haven't written, so maybe the actual takeaway from your experience should be that. [1] For examp…

Self-hosting shouldn't be a chore. Self-hosting should be fun! Sometimes I just do maintenance because I can and I like it, not even because it's needed. I could be making the dumbest incremental changes that don't even net a profit in the end just because I like doing it so much.

To me they are definitely pets and I love them for it.

Re: Self hosting in 2023

#252

Earlier quoted context omitted.

I used to keep a server in my room for a decade and I plan to retire it this year. An hour a month is actually a lot as this overhead is highly non-uniform; the server may work fine for months then need a whole day worth of work, which I can no longer easily sustain. [1] That said, I have of course run lots of softwares I haven't written, so maybe the actual takeaway from your experience should be that. [1] For examp…

This is sort of true of owning a car or a home or basically anything. Of those things, my server requires by far the least amount of maintenance (even considering needing to take a day to do something more invasive maintenance once two years or so). I also think it's perfectly fine if my site is down for a day or so because I'm away on travel and it's gone offline. 89.9999% has five nines as well.

> I also think it's perfectly fine if my site is down for a day or so because I'm away on travel and it's gone offline. 89.9999% has five nines as well.

I think this is the key takeaway: host at home unless you want good uptime.

I don't host from home when I want the page to be available even if:

1. There's a power outage at my home

2. I need to e.g. change a lightbulb, so I have to turn off the power (and therefore my router and server)

3. Someone accidentally switches off either the router or server

Re: Self hosting in 2023

#254
post #129
post #119

Earlier quoted context omitted.

If you're using a modern web server like nginx, then you have to really do something wrong to get hacked serving static files.

That's not really fair, zero days will always exist.

In order to be fair, threat models should be taken into account. People seem to be conflating nation state operations using advanced capabilities worth at least hundreds of thousands of dollars to compromise high value targets/infrastructure with "my pet project may get 0 day'd" which is the exact opposite of being fair. Moreover, if the argument is "zero days will always exist" you may as well stop using technology entirely.

Re: Self hosting in 2023

#255
post #36

I'm still not convinced that self hosting is cheaper though. Where I live, both the electric grid and Fibre connections are unreliable, and the ISP charges about $3/month for a static IP. Assuming 2.5W for a RPi, it takes 1.8kWh a month, costing around $0.25 for electricity. This also has the downside of using residential IPs, having to deal with CGNAT/NAT if the ISP has no static IPs, exposing your home IP, slow dis…

> Assuming 2.5W for a RPi, it takes 1.8kWh a month, costing around $0.25 for electricity. Note that it's virtually free in winter (or cheaper if you have a heat pump or only heat during off-peak hours) as the energy used by the RPi is that much energy not consumed by heaters

And you don't need to pay for a static IP adddress. Just front it with Cloudflare and have a cron job to update your A record regularly via the Cloudflare API.

Re: Self hosting in 2023

#257

I'd never heard of Coolify, but it looks like what I've been searching for, i.e. an all-in-one solution for hosting stuff on a VPS (or Pi). But the docs [1] say it requires a minimum of 30 GB of disk space. Does anyone know if that is accurate? What could possibly be taking up that 30 GB if all I want to do is host a static site and maybe Deno or Node? I'm fairly certain I set something similar up in the past on a mu…

30GB disk space is the recommended disk space to be able to host something with it. Coolify itself is a few hundred MB (thank you, node_modules).

(developer of Coolify here)

Re: Self hosting in 2023

#258

Earlier quoted context omitted.

> Not _exactly_ as easy, you also need a valid https cert, and set up a cronjob to renew it. Web servers like Caddy automate this for you: you just indicate that you want HTTPS for a particular site and the rest is taken care of for you (in the case of public sites and HTTP-01 challenges, at least). Link: https://caddyserver.com/docs/quick-starts/https Even Apache2 has mod_md which does pretty much the same thing (sa…

Can't do http challenges because my ISP blocks port 80 inbound.

> Can't do http challenges because my ISP blocks port 80 inbound.

My ISP also put me behind CGNAT, which effectively meant that all of the inbound traffic got dropped. I worked around that by getting the cheapest VPSes that I could find and then setting up WireGuard and simply forwarding the traffic to my homelab servers. So I got all of the compute that I have available locally, all of the RAM and all of the cheap HDD storage, but a static IP address.

I actually wrote about the process a few years ago: https://blog.kronis.dev/tutorials/how-to-publicly-access-you...

(note that you probably would only want to forward 80 and 443 ports in most cases, not everything; outside of testing boxes)

Personally, I opted for Time4VPS in the end, which I use for the rest of my hosting as well: https://www.time4vps.com/linux-vps/?affid=5294#annually (affiliate link, they do have good discounts at the moment for yearly billing, though)

Then again, something like Scaleway Stardust instances could also be a really good fit, when they are available: https://www.scaleway.com/en/stardust-instances/

For those not chasing after the savings of a few Euros, Hetzner is also going to be more than enough: https://www.hetzner.com/cloud (or DigitalOcean, or Vultr, or any other VPS provider out there)

Re: Self hosting in 2023

#259

Self-hosting is weird. I hear a lot of people say it's so much work, but I put like an hour a month into my server at most. I think it's mostly fine from an administrative standpoint, as mentioned elsewhere, not much has actually changed from 2003. You definitely don't need kubernetes. If anything, I think most of what's changed since then is that there's been a flood of bad sysadmin advice making people believe they…

It's a broad church I think, it depends on what you're self-hosting and why. Email is more work than Nextcloud, and an hour or two of maintenance work feels different when it's a hobby you're doing on a quiet weekend than when you're busy with life and some essential service has gone down unexpectedly.

Security, as well, is a very deep rabbit hole that can be hard to really get your head around unless you have specific training in it. I "self" host some stuff on a public-facing VPS but there are a couple of services I have moved back to third-party hosting because I had persistent anxiety about unexpected downtime or data breaches.

> It's also great to have a beefy always-on computer to run compute jobs flooring all cores of the CPU for 200 hours on and not have to worry about bills later.

What do you mean not having to worry about bills? Presumably flooring your CPU for 200 hours would generate a hefty enough electricity bill or am I misunderstanding?

Re: Self hosting in 2023

#260
post #78

Earlier quoted context omitted.

You can move ssh to a different port.

Anyone who thinks they need to move ssh to a different port likely doesn’t have their ssh security configuration setup optimally.

Moving the port away from 22 changed my fail2ban logs from hundreds of lines a day to one every few weeks at most.

While you shouldn't skip on other security measures, there's no real downside to changing your SSH port and getting off the target list for a lot of botnets.

(As opposed to e.g. port knocking, which is stronger but makes it easy to lock yourself out and may create issues with some SSH clients.)

Post reply on HN