mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 21:50:33 +03:00
nixos/smartd: add option for notifiction email sender
This commit is contained in:
parent
72ff02c99b
commit
f9f48250fe
1 changed files with 11 additions and 1 deletions
|
@ -18,7 +18,7 @@ let
|
|||
${optionalString nm.enable ''
|
||||
{
|
||||
${pkgs.coreutils}/bin/cat << EOF
|
||||
From: smartd on ${host} <root>
|
||||
From: smartd on ${host} <${nm.sender}>
|
||||
To: undisclosed-recipients:;
|
||||
Subject: SMART error on $SMARTD_DEVICESTRING: $SMARTD_FAILTYPE
|
||||
|
||||
|
@ -129,6 +129,16 @@ in
|
|||
description = "Whenever to send e-mail notifications.";
|
||||
};
|
||||
|
||||
sender = mkOption {
|
||||
default = "root";
|
||||
example = "example@domain.tld";
|
||||
type = types.str;
|
||||
description = ''
|
||||
Sender of the notification messages.
|
||||
Acts as the value of <literal>email</email> in the emails' <literal>From: ... <email></literal> field.
|
||||
'';
|
||||
};
|
||||
|
||||
recipient = mkOption {
|
||||
default = "root";
|
||||
type = types.str;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue