Rotation of tar archives
The current implementation of the tar handler creates an unlimited number of tar archives; one per execution of the handler.
Keeping an unlimited number of copies is not always required and in some situation, it may force the sysadmin to write a custom script to take care of the rotation of the oldest copies.
The enclosed patch modifies the tar handler so that it is capable of rotating the archives itself.
The patch does not change the default behavior so that backward compability is assured.
The rotation is configured via a new keyword: "rotate" (named after logrotate's parameter)
The patch also updates ninjahelper's tar helper to add support for this new parameter.
The implementation is very basic but has been successfully doing the job on my server for a month now, without causing any issues.