Commit 22444f1d authored by Leigh B Stoller's avatar Leigh B Stoller

Add mysql log/backup up pruning to crontab, runs once a month.

parent 1b50c21c
# Add add mysql back pruning to /etc/crontab
use strict;
use libinstall;
use installvars;
sub InstallUpdate($$)
my ($version, $phase) = @_;
# If something should run in the pre-install phase.
if ($phase eq "pre") {
# If something should run in the post-install phase.
if ($phase eq "post") {
Phase "crontab", "Updating $CRONTAB", sub {
open(FH,$CRONTAB) or return;
if (grep /backup \-c \-y/, <FH>) {
PhaseSkip("File has already been edited");
"15\t5\t20\t*\t*\troot\t$TBROOT/sbin/backup -c -y");
return 0;
# Local Variables:
# mode:perl
# End:
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment