Add a >24h cleanup cronjob for tus uploads /cc @Acconut @arturi

This commit is contained in:
Kevin van Zonneveld 2016-09-28 09:48:46 +02:00
parent 19a6611a89
commit 785248765d
1 changed files with 9 additions and 1 deletions

View File

@ -146,9 +146,17 @@ setup {
fqdn = "master.tus.io"
}
tasks {
file = "path=/mnt/tusd-data state=directory owner=www-data group=www-data mode=0755 recurse=yes"
file = "path=/mnt/tusd-data state=directory owner=www-data group=ubuntu mode=ug+rwX,o= recurse=yes"
name = "tusd | Create tusd data dir"
}
tasks {
name = "tusd | Create purger crontab (clean up >24h (1400minutes) files)"
cron {
name = "purger"
special_time = "hourly"
job = "find /mnt/tusd-data -type f -mmin +1440 -print0 | xargs -n 200 -r -0 rm || true"
}
}
}
}