cron: fix error when running crontab as sudo (issue #54827)

This commit is contained in:
Aaron Andersen 2019-02-08 12:06:16 -05:00
parent 70765af1a6
commit c8547081cb

View file

@ -1,4 +1,4 @@
{stdenv, fetchurl, sendmailPath ? "/usr/sbin/sendmail"}:
{stdenv, fetchurl, vim, sendmailPath ? "/usr/sbin/sendmail"}:
stdenv.mkDerivation {
name = "cron-4.1";
@ -25,6 +25,9 @@ stdenv.mkDerivation {
#undef _PATH_SENDMAIL
#define _PATH_SENDMAIL "${sendmailPath}"
#undef _PATH_VI
#define _PATH_VI "${vim}/bin/vim"
#undef _PATH_DEFPATH
#define _PATH_DEFPATH "/run/wrappers/bin:/nix/var/nix/profiles/default/bin:/run/current-system/sw/bin:/usr/bin:/bin"
__EOT__