Page MenuHomePhorge

Remove DeleteWiki backups on a regular basis
Closed, ResolvedPublic

Description

Upon wiki deletion, the .sql dump and the .tar.gz dump of the wiki's files are stored into a directory so that a wiki can theoretically be undeleted relatively easily (not that we would've had to ever do that, but just in case, you know) but this directory isn't ever cleaned up so there are some ancient (by Internet standards) backups in there. We probably should have a cronjob in place to regularily clean up the aforementioned directory so that it doesn't accumulate such a load of junk.

Event Timeline

lewiscawte triaged this task as Normal priority.Mar 13 2017, 1:45 PM
lewiscawte moved this task from Restricted Project Column to Restricted Project Column on the Restricted Project board.Feb 25 2019, 2:26 AM

So we now run a find command which pipes to xargs to delete directories under /path/to/settings/deleted that haven't been modified in 30 days. This gives us enough time to hopefully notice we've deleted the wrong wiki or for someone to appeal a deletion (not that we have a formal appeals process) while not hoarding deleted wikis forever.

This runs on a weekly crontab, the script is simply a wrapper called deletedwikiCleanup and is in the scripts repository.