Contabo + Cloudflare: how this server is networked and built

People often ask me how I managed to get a website and how I afford the high costs. Most of these people are fictional characters in my head I created during a shower to develop my thoughts, but still it's something I've been thinking about writing for a while so here it is.

The basic idea to implement

The basic goal is pretty simple: have a website accessible from anywhere. The constraints are what make this issue more interesting: lowest possible costs while maintaining security, privacy, and as much value as possible (storage, speed, etc).

The actors in this don't change. For a website you need:

  1. A computer with storage (to act as a server)
  2. A domain name to access your site from
  3. A DNS to combine the two

For security purposes, the DNS should act as a middle man between the server and the general web. This protects against malicious actors, DDoS attacks, etc. The server needs to know how to handle the traffic and route users in the right direction. The domain name... needs to be good and cheap I suppose. Mine is just my name, which is fairly uncommon so the price was good.

Domain Name and DNS

These two things have remained constant throughout my website owning career (four years now I think). To buy and manage my domain name I use Namecheap because they are true to their name: cheap. Here's how much they cost per year:
- lukeogburn.com: $10.38
- sabrinachin.com: $8.88
- lukeo.link: $10.88
Add an 18 cent ICANN fee to each, about $30 all said and done, roughtly $10 per domain. This also includes the domain, WhoIs protection for privacy, and available DNS (which I don't use). Subdomains are unlimited, which I take full advantage of to run my many Dockerized services.

For DNS I use Cloudflare. Their service is free for basic (personal) usage, which is perfect for me. I can manage all three domains, which includes unlimited subdomains and DDoS protection for everything. They also give me SSL certificates which I go ahead and use, even though I could easily use Let's Encrypt for free. Which I do use, actually, to encrypt traffic between my server and Cloudflare, so the traffic to the client's browser is encrypted with Cloudflare and the traffic from Cloudflare's servers to my hosting server is also encrypted.

My first home server - cost effective

Raspberry Pi's are my best friend. I had a Pi connected to my home router that ran Own Your Bits' NextcloudPi OS.  The Pi only ran Nextcloud and didn't really have the capability to run anything else - not that I would have had the bandwidth anyways. This is a fairly simple home server setup: Raspberry Pi has an external hard drive (from an old computer) plugged in to act as storage, and is connected to my router via ethernet. After port forwarding, anybody accessing my IP address will access the Raspberry Pi server as a website. Hooking my IP address up to Cloudflare under my domain name make it official.

The limit of this server is the bottlenecks of the Raspberry Pi or the network connection of my home internet. It worked well enough for a while but I was dreaming bigger. So I bought a real server with Host Gator. I'm not linking them here because I actually would reccomend Contabo over them. Contabo has the most competitive prices I have seen anywhere, has servers located in Germany (who have very strict privacy laws), offers DDoS protection (redundant with Cloudflare which is perfect), has unlimited bandwidth, and large storage volumes. They really are perfect. After setting up SSH on a different port than default, I set up my services according to my other blog post. Contabo is €3.99/mo for their cheapest plan, working out to €47.88 per year.

Summary

Quick synopsis: after trying a few things like having a server in my living room, I settled on the following:

  1. Namecheap domain name (~$10/domain/yr for a decent .com url)
  2. Cloudflare DNS ($0/yr)
  3. Contabo hosting (€47.88/yr, about $58.15/yr)

And I have everything I want and will want for quite a while. Total cost is 10*3 + 0 + 58.15 = 88.15 per year for a real server to run three real websites that I really built myself. Taking out the server (and running a home server) would only cost ~10/yr for the domain names.

The blogpost is over, but just to brag on how cheap that is, I have unlimited cloud storage for backups and files, a blog, a main website with my resume and portfolio, a URL shortener, a website for my girlfriend, and a VPN setup on my server. I could have a lot more since this setup can scale a lot without increasing in cost. $90/yr is a steal for all of those services to not only have, but to have with complete privacy and da** good security. And I get to nerd out and learn stuff as I go, which is really priceless. But also costs one shift at work.