The goal of this tutorial is to set up a minimalistic Raspberry Pi server that will be fine-tuned to your needs and run headless – no peripherals whatsoever, just the Pi plugged to a router. I will walk you through every stage needed to accomplish that in a user-friendly way and try to explain everything as we go, but there might be a part that you will have to accept without much explanation in the interest of being newbie friendly. You can research those topics on your own at a later time. A lot of administration work is googling stuff anyways, seriously. It is good to know how to do it.
With a proper internet connection and a domain you will be able to ditch Gmail, Dropbox and a few other services almost completely.
Purpose of this tutorial series
This websie serves two purposes
- To document everything I have been doing so far, in case I forget something
- To help you set up a similar server for your own needs
There are many guides on the internet, but I am writing this one since most are not that newbie friendly, complete and coherent, at least they were not for me. Other than that, it is just for my own benefit. If you happen to make use of it, great! Tutorials are divided so that you can pick and choose which services you want on your server.
Server setup tutorial
Your server will be ready after completing the below steps. It might not have any services installed, but it is a great foundation to build upon!
- Part 1 – Required hardware
- Part 2 – DNS configuration
- Part 3 – Installing a minimalistic server
- Part 4 – Basic security
- Part 5 – Port forwarding
For use only on local network it is enough if you install the OS itself.
General purpose tutorials
This section has a few general Linux oriented tutorials to help you understand the operating system and provide some tips.
- Part 1 – Basic commands
- Part 2 – Useful tricks
- Part 3 – Running script
- Part 4 – Partitioning and formatting your drives
- Part 5 – Mounting external storage
- Part 6 – Backup
- Part 7 – Using aliases for convenience
This section has a selection of services that you can set up on your server. A computer on its own does nothing, services are what makes it useful.
- Part 1 – FTP server
- Part 2 – Apache web server
- Part 3 – PHP
- Part 4 – MySQL
- Part 5 – WordPress
- Part 6 – SSL certificate
- Part 7 – Samba file sharing
- Part 8 – Nextcloud server
- Part 9 – Email server
- Part 10 – Webmail access for email
- Part 11 – Mumble VoIP server
- Part 12 – Torrentbox
A word of caution
Bear in mind that using such a server for a company to store sensitive data like payroll or invoices might not be the best idea out there – get yourself a professional who will do that for you, invest in your future. Hackers more prolific than script kiddies and bots can be a bit of a problem. I am talking about actual hackers to whom your server will be exposed should it get enough visibility and not that one person who posted “I eat farts!” on your Facebook wall when you forgot to log out in the library. Keep that in mind when storing your data.
Expanding the knowledge
Remember that Raspbian is a fork of Debian. If you are stuck, need help with a particular command or just want to expand your knowledge, a great place to start is the Debian Administrator’s Handbook by Raphaël Hertzog and Roland Mas.
The link will take you to handbook’s website where you can read it online. There are translations to various languages – some more complete than others. You can also download it as a pdf file or buy a physical copy. It is a great read and will help you a lot. I cannot recommend it enough! Even though it has 500 pages, it can serve as a supplicant of what you learn here.
If I am talking about, for example, packages you can jump to the respective book chapter and learn more. Tutorials have practical knowledge, the book has theory. It does not have all the answers, you will still have to extensively search online regarding specific topics, but it will greatly expand on tutorials from this site.