Inital Setup for tracking changes to files outside of /etc
Before you do anything if you want to add an external configuration you have to create a commit.d hook script to collect those external changes and store them in the mirrored directory in the repo, make it executable and fill it with the script you mentioned. Then run etckeeper commit to commit the hook script to the repo. (At this point it won't really do much provided you've removed the examples from the script).
Adding files and directories to etckeeper
Next, and this step will be repeated for any new files or directories added to etckeeper's repo over the life of the server...
For each file or directory, to the end of the commit hook script add a call to one of the folllowing functions specifying the path to the file or directory as an argument:
Files:
mirror_file "/var/blah/bar.conf"
Directories:
mirror_dir "/var/foo"
Next then you need to run etckeeper commit and it will display the following message:
etckeeper: mirroring outside files to /etc/etckeeper.mirror.d: <file or director name>
and after you wait a bit (depending on how much you've stored, which probably shouldn't be much) it will ask you for a commit message.
Let me just see if I'm doing this right...
Inital Setup for tracking changes to files outside of /etc
Before you do anything if you want to add an external configuration you have to create a commit.d hook script to collect those external changes and store them in the mirrored directory in the repo, make it executable and fill it with the script you mentioned. Then run etckeeper commit to commit the hook script to the repo. (At this point it won't really do much provided you've removed the examples from the script).
Adding files and directories to etckeeper
Next, and this step will be repeated for any new files or directories added to etckeeper's repo over the life of the server...
For each file or directory, to the end of the commit hook script add a call to one of the folllowing functions specifying the path to the file or directory as an argument:
Files:
mirror_file "/var/blah/bar.conf"
Directories:
mirror_dir "/var/foo"
Next then you need to run etckeeper commit and it will display the following message:
etckeeper: mirroring outside files to /etc/etckeeper.mirror.d: <file or director name>
and after you wait a bit (depending on how much you've stored, which probably shouldn't be much) it will ask you for a commit message.