[Nix-dev] How to get cron to use msmtp?

Joachim Schiele js at lastlog.de
Fri May 29 01:40:22 CEST 2015


On 28.05.2015 21:00, Anders Lundstedt wrote:
> By default, cron tries to use /var/setuid-wrappers/sendmail to send
> mail, as seen in line 25 in:
> 
> https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/scheduling/cron.nix
> 
> I have tried
> 
> nixpkgs.config.packageOverrides = pkgs: {
>   cron = pkgs.cron.override {
>     sendmailPath = "/run/current-system/sw/bin/msmtp";
>   };
> };
> 
> but no success.
> 

try

nixpkgs.config.packageOverrides = pkgs: {
  cron = pkgs.cron.override {
    sendmailPath = ${pkgs.msmtp}/bin/msmtp;
  };
};



More information about the nix-dev mailing list