I have previously written about using Git to add revision history to existing rsync backups. Having performed a number of configuration changes and system upgrades recently, I have found another use of Git which has proven invaluable.
It’s a fairly obvious hack, but it turns out that turning selected configuration directories (for example /etc/apache2/
and /etc/exim4/
) into in situ Git repositories is a very handy thing to do.
The revision log you get in a Git repo gives you a very handy place to note down the reasons behind a certain configuration change. This provides a very handy historical context for a change, meaning you’re less likely to remove something odd that turns out later on to have been important.
Having configuration under version control also means that even if you do accidentally remove or change something that later causes problems you can easily roll them back.
Another handy feature is the ability to easily branch, so you can very quickly experiment with some wild configuration settings and very quickly revert them to the original working configuration should they turn out to be problematic or if you run out of time to complete them.
So, give it a try!