Skip to main content

New answers tagged

7 votes

Bash script for manually cleaning up the Traefik access log file and limiting it to a maximum of 50 MB

log rolling races I can't imagine why you chose to re-invent the wheel here (and the original posting is not so tagged). Log rolling is a mature and well studied need, with good solutions such as the ...
J_H's user avatar
  • 43.3k
9 votes

Bash script for manually cleaning up the Traefik access log file and limiting it to a maximum of 50 MB

Log rotate At first it was unclear to me why you chose this approach rather than take advantage of the various log rotate options that are available in Traefik (docs). But it turns out that Traefik ...
Kate's user avatar
  • 8,778
7 votes
Accepted

Bash script for manually cleaning up the Traefik access log file and limiting it to a maximum of 50 MB

Overall, looks good to me. Just some minor nitpicks: size=$(stat -c%s "$fn") That's a case where set -e won't ...
Toby Speight's user avatar
  • 88.7k
6 votes
Accepted

Bash tool for automating Telnet/SSH commands with live interactive session takeover

What's Good The script shows solid understanding of several advanced bash concepts: Named pipes for bidirectional communication with telnet Proper cleanup with <...
chicks's user avatar
  • 2,964

Top 50 recent answers are included