Add SMART monitoring
This commit is contained in:
parent
9ddf94f567
commit
c03e5601ba
|
@ -90,6 +90,7 @@
|
|||
./modules/networking.nix
|
||||
./modules/datasync.nix
|
||||
./modules/virtualization.nix
|
||||
./modules/monitoring.nix
|
||||
];
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,23 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
# Notify when a disk starts going haywire
|
||||
services.smartd = {
|
||||
enable = true;
|
||||
notifications.mail = {
|
||||
enable = true;
|
||||
recipient = "akasroua@gmail.com";
|
||||
};
|
||||
};
|
||||
|
||||
# Enable trivial MTA for smartd notifications
|
||||
services.ssmtp = {
|
||||
enable = true;
|
||||
useTLS = true;
|
||||
useSTARTTLS = true;
|
||||
domain = "gmail.com";
|
||||
hostName = "smtp.gmail.com:587";
|
||||
authUser = "akasroua@gmail.com";
|
||||
authPassFile = "/var/keys/ssmtp";
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue