mirror of
https://github.com/jayofelony/pwnagotchi.git
synced 2025-07-01 18:37:27 -04:00
delete logs after rotation
This commit deletes the logfile after compression. The current rotation keeps the logfiles which quickly fills up any zram compressed log mounts which will cause the pwnagotchi to hang. Signed-off-by: SK <74106733+skontrolle@users.noreply.github.com>
This commit is contained in:
@ -307,3 +307,5 @@ def do_rotate(filename, stats, cfg):
|
||||
with open(log_filename, 'rb') as src:
|
||||
with gzip.open(archive_filename, 'wb') as dst:
|
||||
dst.writelines(src)
|
||||
|
||||
os.remove(log_filename)
|
||||
|
Reference in New Issue
Block a user