[Haskell-beginners] running shelly script from root's crontab

Emanuel Koczwara poczta at emanuelkoczwara.pl
Fri Jul 12 15:59:16 CEST 2013


Hi,

Dnia 2013-07-12, pią o godzinie 14:39 +0100, Miguel Negrão pisze: 
> Hi
> 
> I have a shelly script that runs fine from my user account which I would 
> to run every night. It needs to sudo to call some other processes so I 
> need to add it to the root's crontab (sudo crontab -e). Unfortunately 
> the script will fail to run because it can't find several modules, since 
> it's running from the root account. Is there a way to make this work 
> without having to install the packages globally (sudo cabal install 
> --globally) ? I just tried that and manage to completely ruin my haskell 
> installation, so I had to revert to previous backup.

  Try: 'su - user_name'

Best regards,
Emanuel

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 5185 bytes
Desc: not available
URL: <http://www.haskell.org/pipermail/beginners/attachments/20130712/547d213a/attachment.bin>


More information about the Beginners mailing list