Live data from Hacker News

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

news.ycombinator.com

131–140 of 194 posts

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

#131

Setting up WireGuard is definitely the way to go. I learned a ton about networking doing that. It's a beautifully elegant implementation and actually very easy, but it exposes a lot of networking concepts that are important to understand. Don't use PiVPN and the like, just install it and write the configuration files manually. I used WG to get two homes talking to each other. A Pi at each end running WG, with static…

This is definitely a direction I will explore.

> in cities and other areas that actually have competitive markets for ISP

Ho, ho. Out my window I just LITERALLY saw a bald eagle swoop down on a tumbleweed.

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

#132

Start by reading about docker and docker compose. You will have almost everything in docker containers. Pay attention to the basic networking part. Especially where it says that you can refer to a container by name in your configurations Then have a look at Caddy, a web server, to use it as a reverse proxy. You will end up with very simple configurations Read about reverse proxy in caddy's excellent doc. Test on a ma…

> Start by reading about docker and docker compose. You will have almost everything in docker containers.

The case for Docker if you don't care about containerization or any of that per se is:

1) It's basically a very-up-to-date cross-distro package & service manager for Linux servers. You can ignore a ton of stuff about your underlying distro if you use Docker, and can use a very stable LTS Ubuntu or stable Debian or whatever and still have recent versions of the services you care about, more easily than you can without it. Anything you learn about managing Docker will transfer to any other distro.

2) It makes backups and recovery of the exact same services (including same versions) easy by default. Most packages are forced by its nature to make important data directories explicit, you can map those wherever you like on your host system's filesystem, and it's very easy to test whether you're backing up all the stuff you need for recovery from scratch (destroy and recreate the container—if you've mapped all the directories you ought to, it'll look exactly the same, nothing missing or broken, when it comes back up). Back up your mapped directories from various containers (since you can define where these live, this may be as simple as backing up a single directory), backup the docker-compose.yml or shell scripts or whatever you're using to define and start up your services, and that's just about everything.

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

#133
post #128

You sound like you are on a good trajectory. I'd start reading up on and implementing a firewall. Start with host based, then on a router/vlan firewall. Try out wireshark and view things like a simple wget, file download, and similar. If something weird is going on record with tcpdump (see wireshark docs for flags) and you can analyze afterwards with wireshark. I'd recommend an IPv6 firewall if you can get IPv6, that…

SUPER helpful. Very grateful!

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

#134

The reality is that we've let you down. Self-hosting shouldn't be any more complicated or less secure than installing an app on your phone. You shouldn't need to understand DNS, TLS, NAT, HTTP, TCP, UDP, etc, etc. Domain names shouldn't be any more difficult to buy or use than phone numbers. Apps should be sandboxed in KVM/WHPX/HVP-accelerated virtual machines that run on Windows, Mac, and Linux and are secure-by-def…

Interesting projects! I bookmarked boringproxy for later reference. Just a quick comment: the feed on your homepage is nice - like a personal timeline - but it misses an RSS feed! ;)

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

#135

The reality is that we've let you down. Self-hosting shouldn't be any more complicated or less secure than installing an app on your phone. You shouldn't need to understand DNS, TLS, NAT, HTTP, TCP, UDP, etc, etc. Domain names shouldn't be any more difficult to buy or use than phone numbers. Apps should be sandboxed in KVM/WHPX/HVP-accelerated virtual machines that run on Windows, Mac, and Linux and are secure-by-def…

Wow. “The system fundamentally fails us AGAIN RAWR” is a hot take that I almost always go to eagerly, but I am vibing SO HARD on hitting the front page of HN (!!!?) and getting the community help glow, that for the moment I’m gonna let it go. :-)

Also, thanks for all the helpful tips.

At this point there is so much for me to go on that I am trying to think how I can put it all together and share it.

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

#136
post #128

You sound like you are on a good trajectory. I'd start reading up on and implementing a firewall. Start with host based, then on a router/vlan firewall. Try out wireshark and view things like a simple wget, file download, and similar. If something weird is going on record with tcpdump (see wireshark docs for flags) and you can analyze afterwards with wireshark. I'd recommend an IPv6 firewall if you can get IPv6, that…

SUPER helpful. Very grateful!

Generally new admins tend towards creating physical or virtual machines, logging in as root, editing files, starting services, and backing them up.

Which is fine, a great way to learn, a less great way to be in production. Upgrades can be painful, it's easy to break things is non-obvious ways, and there's no easy "undo".

Generally I'd recommend either using containers and maintain your build scripts in git, or use some configuration management software like ansible or puppet (there are many others as well) so you can install a new OS (virtually or physically), then have ansible/puppet/whatever add config files, packages, services etc to get things working. Of course then you keep ansible/puppet/whatever files in git AND back them up.

That way if there's some major upgrade of OS or software you can spin up a test env, test it, and then decide to promote/replace an existing machine ... or just ditch it.

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

#137
post #136

Earlier quoted context omitted.

SUPER helpful. Very grateful!

Generally new admins tend towards creating physical or virtual machines, logging in as root, editing files, starting services, and backing them up. Which is fine, a great way to learn, a less great way to be in production. Upgrades can be painful, it's easy to break things is non-obvious ways, and there's no easy "undo". Generally I'd recommend either using containers and maintain your build scripts in git, or use so…

Really good advice. I still have flashes of “Ohhhh righhhhhht it’s a VIRTUAL machine---I can...” make a snapshot, clone it and test new stuff, etc. etc. etc. I’ll be happy when it fully sinks in.

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

#138
I'd recommend you to check out the specialized self hosting distros and systems such as FreedomBox , Sandstorm.io, yunohost or Cloudron . I have not used it myself, so i cant recommend which system to use. However i have gone trough the pain of setting up loads of self-hosted apps. Especially if you really want to use your system, not maintain it all the time you will search for the most easy solution. There is nothing more annoying then to fix your system every month before you can continue working. I would also love to hear from people using these systems on a daily basis. Another possibility for lots of self-hosted apps is a NAS (Synology or QNAP). However not everything runs on these systems, sometimes because they are not available, sometimes because the hardware cannot be upgraded.

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

#139
There are several projects designed to help you self-host your own services.

Proxmox[0] is mentioned by a few folks here. It's mostly a hypervisor. It's good if you have a "big" server and want to split it up into VMs for various needs. It doesn't have any concept of an AppStore or service catalog. I think this is too low level for what you're asking.

Unraid [1] is probably the easiest way to turn an arbitrary computer into a useful server. You install the OS on a thumb drive and it runs from there. It provides network storage services out of the box, can host VMs, and has a solid catalog of packaged services in their Community Applications plug in [2]. These are packaged in weird obscure way that I tried and failed to figure out. I've run this on an old T410 for a couple years and it's been pretty good. Not as flexible as some other options, but quick to get going on the basics. You can see this in their storage system... you can easily add arbitrary disks to your pool, but parity options are limited. My biggest complaint is that it's hard to spin up your own docker images, especially if you don't want to mess with Docker Hub.

TrueNasSCALE [3] is my next platform. It's an iteration on the very solid FreeNAS/TrueNAS and ZFS. It handles containers and containerized services as first-class citizens using kubernetes, but also includes KVM so you can do virtual machines. Like Unraid, it has a healthy app library over at TrueCharts [4]. Unlike Unraid's weird XML manifest, SCALE uses Helm. Nice.

coolLabs [5] is sort of a self-hosted Heroku alternative. I just discovered it on HN the other day [5a] in that context. It looks pretty neat. It has some pre-packaged services already [6] but seems to lack any concept of a community-curated service package repo. It seems to be mostly focused on helping you deploy applications you develop yourself. I don't think it gives you network shares, for example. Still, it could be a great choice to throw onto the VPS you're wonder what to do with. [7]

Kubesail [8] is a k3s-based self-hosting operating system. It's designed to help you run basic web services as easily as possible. Where Unraid assumes you have an old computer laying around, Kubesail will sell you a PiBox [9] to get you up and running. (You can also bring your own hardware). The have a nice AppStore and have put particular attention into the photo use case you mentioned - they emphasize support for PhotoStructure [10].

Cloudron [11] was mentioned by a few other comments. I haven't dug into it, but it does seem to have an appstore as well.

[0] https://www.proxmox.com/en/

[1] https://www.unraid.net/

[2] https://unraid.net/community/apps

[3] https://www.truenas.com/truenas-scale/

[4] https://truecharts.org/

[5] https://coollabs.io/

[5a] https://news.ycombinator.com/item?id=33077118

[6] https://docs.coollabs.io/coolify/services/

[7] https://docs.coollabs.io/coolify/installation

[8] https://kubesail.com/homepage

[9] https://pibox.io/

[10] https://kubesail.com/template/erulabs/photostructure

[11] https://www.cloudron.io/

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

#140

There are several projects designed to help you self-host your own services. Proxmox[0] is mentioned by a few folks here. It's mostly a hypervisor. It's good if you have a "big" server and want to split it up into VMs for various needs. It doesn't have any concept of an AppStore or service catalog. I think this is too low level for what you're asking. Unraid [1] is probably the easiest way to turn an arbitrary comput…

Thank you for compiling this list.
Post reply on HN