lastns
This commit is contained in:
9
daily.d/lastn_clean.sh
Executable file
9
daily.d/lastn_clean.sh
Executable file
@@ -0,0 +1,9 @@
|
||||
#! /usr/bin/env bash
|
||||
|
||||
now=$(date +%s)
|
||||
for f in /volume1/video/FTP/2???.??.??.*; do
|
||||
s=$(date -r "$f" +%s)
|
||||
if ((now-s > 60*60*24)); then
|
||||
rm -f "$f"
|
||||
fi
|
||||
done
|
||||
Reference in New Issue
Block a user