Forget about serverless
Beware! You will get insight into my unglamorouse server setup.
I host web sites and web applications on my own hardware which resides at my home. Previously it was a Raspberry Pi 1 Model B and now it's an Odroid M1 with 8 GB of RAM.
Dynamic DNS makes sure that my server is reachable from the internet.
Operating system is Linux in the flavor of Ubuntu. It's a headless, stock server version. All server management is done via the terminal and SSH. I started to take advantage of the server configuration tool Ansible which helps reducing configuration drift. It's lean and is fast to learn.
I deploy applications and copy data the traditional way via rsync
or tar
. Still I treat deployments as immutable batches when possible. It means that I create a new folder for a new version of the app instead of overwriting files. Then I update the symbolic links. Use mv
to move it into place so that it's an atomic operation!
I run web apps on mainly two technologies. Blog is written in PHP and the other apps are NodeJS. In front of those apps sits Nginx with a boilerplate configuration from the HTML5 Boilerplate project as a reverse proxy.
Mostly, I write scripts in Python, NodeJS, and POSIX shell. Standard UNIX utility programs help me to get a lot of work done. Some special ones I'd like to point out: curl
, pup
, xmllint
. They do some heavy lifting for accessing HTTP APIs and parsing the responses.
For persistence my go-to solution is SQLite with bindings in the aforementioned languages and its command line app. Apps and likewise all the scripts write to multiple databases. Watch out for multiple processes concurrently writing to one database which SQLite isn't made for! Great piece of software that does a perfect job for a wide variety of apps and is blazingly fast.
I also host my own mail server. It runs the pre-built Docker image of this awesome project.
What's left?! Backups!! Rsync
, tar
with some further down Borg Backup solution.