I’ve been wanting to get into self hosting for a long time and messed about a bit with setting up a nextcloud. But while I am reasonably well versed in linux and programming all things to do with the internet are quite confusing and mostly after reading blogposts and the like I am feel like I am missing so much knowldedge. From why people use traefik, how and why to use docker containers, what settings to change on the router, how to connect and setup the domain, and probably most importantly how to do this safely. Is there a good book or site that explains these more basic things?
Computer networking is basically a completely different field from operating systems and programming, though obviously some of the concepts are relevant. Turns out plugging these things into each other so that they can share information in a useful way is kind of difficult. A lot of very smart people have been working on it for almost 70 years, and frankly it’s still a fucking mess, so don’t feel bad if you feel a little lost.
Starting with the basics is the right instinct, in my opinion. Start with the OSI model:

https://jakarta.telkomuniversity.ac.id/7-osi-layer-the-building-blocks-of-networking/
https://www.geeksforgeeks.org/computer-networks/osi-model-analogy-osi-7-layers-explained/
This helps to break down the actual functioning of the network into logical steps. It’s very helpful when you’re trying to visualize the operation of some of the more abstract bits of the technology stack (like TCP/UDP), and when you’re trying to think through what piece of it might be causing your problem in the moment (the router is on and the cables are plugged in, why is there no connection?). It’s a map that can help you when you’re lost. It’s also a guide to how a lot of people who work on networking technology think, so it can help you understand how things are supposed to work.
Beyond that, Professor Messer is a great resource: https://www.professormesser.com/
If you feel reasonably confident with computer hardware components and various types of cable connectors, you can probably skip the A+ part and go straight into Network+. Because you’re doing this as a home hobbyist (not for the actual certification), I recommend just listening to the courses like you would a podcast. Don’t try to memorize or fully understand everything, just use it to get a grasp of the terminology and purpose of the various pieces.
I also recommend taking on a project to gain experience. Implenting PiHole https://pi-hole.net/ for your home network will cover routing, DHCP and DNS, plus you can do it with a Docker container.
it can help you understand how things are supposed to work.
Man knowing what the intent probably was and the thought process to get there helps with so much troubleshooting. Not just in tech but everywhere.
Here’s a good catch-all guide, written by Louis Rossman (divisive but respected Right-to-Repair activist):
Adding the security basics, since nobody listed them yet:
- A firewall with default deny, then open only what you need. A simple one such as ufw is fine.
- Install CrowdSec or fail2ban early. Within a day you will see how much junk hits any public server.
- Reach SSH and admin pages over a private network (Tailscale or WireGuard) instead of exposing them.
- Read your reverse proxy access log for a week. It teaches you more about how the internet really behaves than most courses.
None of it has to be perfect on day one, but it is much easier to build in from the start.
Start small and basic. Pick a service you want to host and then decide how you want to access it and ask questions. Over time it won’t seem so insurmountable.
If you have a bunch of questions list them and we will do oir best to answer them.
Following because I am really a beginner myself. That said, I have been self-hosting a dozen or so services for about 2 years now. It is very intimidating to begin.
A docker container is basically a sort of virtual machine stripped down to what is precisely essential for a given container. That means that apps running in docker are repeatable and will run identically on any hardware and software.
When it comes to networking, you can choose to have services exposed to the internet or not. If they are not exposed, you can only access them over a local network. That might be fine for a nightly backup or HomeAssistant that’s only operated locally. It’s a good place to start.
You can also use a certain type of VPN to create a virtual local network. That allows you to access your home server from any connected device. That’s what I do, using Tailscale. It is fine if you are only connecting to the server from a limited number of devices, since each one will need to be logged in to the same network.
No, there is not one resource for all of these things. Any guide that takes you end to end setting up one service is going to omit a lot of important context. I would research each step individually.
To your specific questions:
why people use traefik
Reverse proxies let you serve multiple apps from one server, encrypt your traffic and automate updates of encryption certificates. I use Apache (virtual hosts, mod_md) for this.
how and why to use docker containers
Modern web apps have many constantly shifting dependencies and don’t work closely with distributions on packaging them, so they have to be updated separately from the base system. They might also need different versions of these dependencies, and multiple instances of one dependency (e.g. database). Containers are one way to achieve that, and also ease backups, monitoring of individual apps, and installing an application in exact same way on development and testing machines.
what settings to change on the router
To expose ports 22 (ssh), 80 (http) and 443 (https) to world, forward them to your server.
how to connect and setup the domain
In the DNS settings for your domain, point “A” record to your home IP. That’s if you rent a static IP. If you don’t, things will be more complicated, research on your own.
how to do this safely
Bare minimum: set up daily backups of container volumes and reverse proxy configuration, same for updates of base system and containers, and turn off SSH password login in favor of keys. Test that a backup can be successfully restored in a virtual machine at least once a month.



