Commit b04a9e64 authored by Vincent Le gallic's avatar Vincent Le gallic
Browse files

Je veux pas t'entendre quand tu logrotate les logs du firewall.

Fix de 0b22dda0, il manquait un truc.
parent 10b56a4a
......@@ -11,7 +11,6 @@ if [[ `hostname` == 'komaz' ]]; then
else
exit 41
fi
logs_dst="/home/squid/`hostname`/logs"
if [ ! -d "$logs_dst" ]; then
......@@ -20,7 +19,7 @@ if [ ! -d "$logs_dst" ]; then
fi
# tant qu'il existe un fichier, le sauvegarder (<!>)
while ( ls -tr "$logs_src" | grep -E 'logall\.log\.[0-9]+\..z2?' ); do
while ( ls -tr "$logs_src" | grep -E -q 'logall\.log\.[0-9]+\..z2?' ); do
dernier_fichier=$logs_src/$(ls -tr "$logs_src" | grep -E 'logall\.log\.[0-9]+\..z2?' | head -1)
#timestamp=$(bzcat "$dernier_fichier" | head -1 | awk '{print $1}')
......
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