I have been running a homegrown NAS with Ubuntu for a couple of years now. It basically serves as filestorage for media, including photos taken over a number of years. Previously, I had a Synology Diskstation, but I was lacking some of the flexibility in running a fullfledged server - I wanted more control over my storage and backups.
Up until now, I've been running everything manually, by installing packages, running scripts etc., but it seemed to me I lost a lot of historical data that way. If I at one point have to reinstall my NAS, I'd have to go through all the motions again, reading up on installations of NFS, SnapRaid etc.
So, I decided to try out an automated solution, documenting my setup in the process.
Picking the right tool for the job
There's a bunch of configuration management tools outthere, as the field has grown over the last years, making it a lot harder to pick one without doing some detailed research.
Personally, I've had my hands on Chef and Puppet over the years, but at certain points they both seem cumbersome to me - at least for small-scale projects like the one I wanted to try it out on.
Ansible is an automation engine, written in Python and YAML, used for automating configuration management and deployment. Instead of having a client/server setup like Puppet for instance, it relies solely on a client (in this case that would be my Mac) and an SSH connection to the server you want to setup, making it a perfect suit for smaller, simpler setups like a personal NAS etc.
The syntax seems very simple to me, using YAML makes most playbooks very readable and the commands easily understandable.
In general, there's a lot of easily accessible playbooks for most things (Just try searching on GitHub for Ansible), like setting up NFS, running Apache etc., so Ansible is very easy to get started on, especially if you've tinkered with configuration files previously.
Getting started on the setup
As I already have a server running, I'll be introducing Ansible all over, one service at a time - eventually transforming all the manual setups into Ansible ones. I haven't yet found a service that could magically transform an existing setup into an Ansible one (not properly, at least) - but again, that would probably have kept me from actually learning the proper syntax.
You can follow the work on my Ansible playbook for my NAS while I'm building it on GitHub