Live data from Hacker News

Ask HN: How can a total beginner start with self-hosting?

news.ycombinator.com

161–170 of 194 posts

Re: Ask HN: How can a total beginner start with self-hosting?

#161
post #63

* Buy a domain as Domain * Buy a Asustor AS5304T as NAS * Setup CloudFlare on Domain * Setup services as docker containers on NAS * Setup CloudFlare tunnel into NAS docker services with auth in CloudFlare * Enjoy services. Note, if any of that sounds hard I must kindly point out that you're playing a risky game trying to do all this yourself securely and should evaluate whether it's easier to just pay a service for a…

Can you explain your second last star?

I think he means that you don't point your domain's public DNS records straight to your home IP (where your NAS sits), but rather via Cloudflare.

If so, doesn't Cloudflare do HTTPS termination? Meaning that all your photos would be visible to them during transit.

Re: Ask HN: How can a total beginner start with self-hosting?

#162
To simplify my setup I bought a Synology NAS, crammed disks into it, then setup a bunch of Docker instances on it.

I have game servers for the kids on it, plex, pihole, home assistant and a few others plus I keep adding to it. I setup a static IP the otehr day and a cloudflare account to proxy things through it. Later I plan on setting up a VPN service (probably Tailscale) and maybe look at the cloudflare zero trust setup.

I'm contemplating putting a mail server up as well. all of this in docker instances on my NAS. its cheap effective, simple and damned effective for home use. There is a good community about it and lots of online guides.

This way I dont have to worry/spend too much time on hardware and OS level stuff and can just setup docker apps for the new needs i have. it lets me play around while not burning too much home time while adding services and capability to my family. Seriously.. look into it.

Re: Ask HN: How can a total beginner start with self-hosting?

#163
I can’t promise any specific advice, but as someone who runs a number of self-hosted services for mostly ideological purposes (see https://compose.seedno.de/ for a subset) and works professionally in networking, I’m always happy to chat about my own experiences and suggestions!

Feel free to email me at lab (at) seedno.de to chat!

Re: Ask HN: How can a total beginner start with self-hosting?

#164
post #153
post #79

Earlier quoted context omitted.

Another example of just the kind of concrete answers I was hoping for.

Once you have a stable setup you could even shut off public SSH and instead have it available only over Wireguard (I saw you already mentioned Tailscale). Tor Hidden Services are also an option that are straightforward to set up (you don't even need to think about fw/nat as long as you have tor access) but a bit off gaps in terms of recent accessible docs. If comments indicate interest I may get around to publishing…

Registering interest!

Re: Ask HN: How can a total beginner start with self-hosting?

#165

Earlier quoted context omitted.

Why is the self host advice to always buy a Raspberry Pi, use an old crappy computer you have lying around, etc? I have a very beefy desktop for the first time in over a decade (maxed out Mac Studio) and I am wondering is there any real downside to having these services run on it?

Mostly because you want a dedicated device to serve off of. If your desktop is always on it isn't that much different. My desktop gets shut down, rebooted, crashed, wiped and reloaded, and otherwise abused as I get thoughts. My home server has been the same (don't worry I run updates) for a couple years, chugging along, sipping about 1/4 the power my desktop would take. In the beginning of your self hosting journey,…

I have Pi's and old, beefy computers and what I really need is an "elastic personal cloud" where I can bring up the high-powered computer(s) online on demand[1]. I have WiFi-connected sockets and a python script than can turn them on or off, but no orchestration or global state.

1. My 12-year old, former top-of-the-line laptop is much faster than my 3rd-gen Pi when periodically ingesting and indexing JSON into a PostgeSQL db, I suspect slow IO and limited memory are to blame.

Re: Ask HN: How can a total beginner start with self-hosting?

#166
post #56

Earlier quoted context omitted.

The only downside is, I believe, the electricity bill. The reason to use a rpi is that it has enough computational power to do many useful self-hosting tasks while consuming only a fraction of the power of a beefy computer.

Mac Studio idle is 11 W (max 115 W) compared to RPI 4 idling at 4 W (max 6 W). It's reasonable to assume that the 115 W on a Mac Studio will never be hit on a workload that could be supported by a RPI...so you're looking at an extra $10-20/yr to operate the Mac Studio. The biggest issue is just the upfront cost, since of course the Mac Studio is proportionally expensive to its capability.

Idle power consumption for Apple Silicon Mac is low despite it's workstation, it's outlier. Average Intel desktop consumes similar or a little more power for idle, that is acceptable IMO for flexibility and reuse. Maybe DIY PC consumes a bit more than average Dell desktop even if CPU is same. Average Intel workstation/server consumes much more than them so it's wasteful for almost idle server. So it depends on what is the previous PC.

Re: Ask HN: How can a total beginner start with self-hosting?

#167

My thought on networking is to make sure you only expose SSH and HTTPS; firewall everything else off. SSH seems like a constant source of problems for people new to running servers; within seconds of your server coming online, people will be trying to guess usernames and passwords. Configure it so you can't log in as root, and you can only authenticate with a key. These folks will never guess your key in a billion ye…

> Put your other services behind that proxy, and have them listen on 127.0.0.1 and not 0.0.0.0

Apologies for this newb question, but if you will be adding a proxy, aren't you required to bind it to 0.0.0.0, since if you bind it to 127.0.0.1, only a request within the service's host will be able to receive a response? I'd like to know what I'm misunderstanding here.

Re: Ask HN: How can a total beginner start with self-hosting?

#168
post #14

For hardware: in the past, I would say start with a raspberry pi. But those are impossible to find at list price now. So instead, if you look on ebay for SFF (small form-factor) workstations, you can find something like an HP Prodesk G1 with cpu/storage/memory for ~$50-60. Which is significantly cheaper than a raspberry pi 4B @ $100+ by resellers. Slap on a distro, and you're off to the races. Checkout /r/homelab and…

I've got a 2012 or so Pi in a drawer...! Maybe I can play around with it.

I suspect that the Pi is the first one that only support armv6 that is pain. Newer Pis are good but now it's shortage. I'll buy random SFF PC https://www.servethehome.com/introducing-project-tinyminimic...

Re: Ask HN: How can a total beginner start with self-hosting?

#170
Look at serverbuilds.net to learn how to find the right hardware to buy to host your selfhosted apps.

Look into some VM hosting Hypervisor. I am using VMware because that is what all my jobs have been using. You can use ESXi for free. You could also look into something like proxmox.

If you buy and build right, you could have enough CPU bandwidth and memory to all that you would want. Put all your VMs on SSDs, multiple VMs sharing a single HDD could be considered a war crime.

Learn docker and docker-compose. Use https://www.composerize.com/ to help in the transition from docker to docker-compose. Have a look at linuxserver.io for already built docker images for most of what you want to do.

Keep an eye on Humble Bundle for a DevOps or networking/sysadmin book collection.

If you want to roll your own firewall and router, look into pfSense.

It takes a while to learn and understand, but it is worth it.

Post reply on HN