Only keep 7 days of logs
This commit is contained in:
parent
249aa0a4bf
commit
ef29560c7c
|
@ -72,5 +72,11 @@ with lib; {
|
||||||
services.iperf3.enable = true;
|
services.iperf3.enable = true;
|
||||||
environment.systemPackages = with pkgs; [ iperf ];
|
environment.systemPackages = with pkgs; [ iperf ];
|
||||||
}
|
}
|
||||||
|
# Don't store logs longer than 7 days
|
||||||
|
{
|
||||||
|
services.journald.extraConfig = ''
|
||||||
|
MaxRetentionSec=7day
|
||||||
|
'';
|
||||||
|
}
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,6 +14,11 @@ in with lib; {
|
||||||
recommendedGzipSettings = true;
|
recommendedGzipSettings = true;
|
||||||
recommendedProxySettings = true;
|
recommendedProxySettings = true;
|
||||||
};
|
};
|
||||||
|
# Only keep 7 days of logs
|
||||||
|
services.logrotate.settings.nginx = {
|
||||||
|
rotate = 7;
|
||||||
|
frequency = "daily";
|
||||||
|
};
|
||||||
})
|
})
|
||||||
(mkIf nathan.services.nginx.acme {
|
(mkIf nathan.services.nginx.acme {
|
||||||
security.acme = {
|
security.acme = {
|
||||||
|
|
Loading…
Reference in New Issue