clear logs hourly
This commit is contained in:
parent
9f40a68eb4
commit
6e507ec688
3 changed files with 36 additions and 7 deletions
|
|
@ -26,6 +26,35 @@ in {
|
|||
};
|
||||
};
|
||||
|
||||
users.users.root.openssh.authorizedKeys.keys = ["ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHxah5pnxmk=P7HtwRsryDoAHZsDs5RcGP9IPCNg1KFe cardno;16-179-196"];
|
||||
users.users.root.hashedPassword = "!";
|
||||
users.users.anon = {
|
||||
isNormalUser = true;
|
||||
extraGroups = ["wheel"];
|
||||
hashedPassword = "$6$GAyfgaTQgaBipAbb$gF/9YBh2ucVa/9vDQvEu9DVjSbsqdvSoXwA5RX0kP7.xdCfLqXhGBLlSXHg0e4rkLLd6zI1gRTWd4TfMjnnpS/";
|
||||
openssh.authorizedKeys.keys = ["ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIHxah5pnxmk+P7HtwRsryDoAHZsDs5RcGP9IPCNg1KFe cardno:16_179_196"];
|
||||
};
|
||||
security.sudo.wheelNeedsPassword = true;
|
||||
|
||||
systemd = {
|
||||
services.clear-var-log = {
|
||||
description = "Clear /var/log directory";
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
ExecStart = "${pkgs.coreutils}/bin/rm -rf /var/log/*";
|
||||
User = "root";
|
||||
Group = "root";
|
||||
};
|
||||
};
|
||||
timers.clear-var-log = {
|
||||
description = "Hourly timer to clear /var/log";
|
||||
wants = ["clear-var-log.service"];
|
||||
timerConfig = {
|
||||
OnCalendar = "hourly";
|
||||
Persistent = true;
|
||||
Unit = "clear-var-log.service";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
system.stateVersion = "25.05";
|
||||
}
|
||||
|
|
|
|||
|
|
@ -3,10 +3,10 @@
|
|||
# details gathered from the active system.
|
||||
networking = {
|
||||
nameservers = [
|
||||
"213.136.95.10"
|
||||
"213.136.95.11"
|
||||
"2a02:c207::1"
|
||||
"8.8.8.8"
|
||||
"9.9.9.9"
|
||||
"149.112.112.112"
|
||||
"2620:fe::fe"
|
||||
"2620:fe::9"
|
||||
];
|
||||
defaultGateway = "157.173.112.1";
|
||||
defaultGateway6 = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue