Follow

I just had to figure out why a shellscript working perfectly was refusing to do anything, even quit, as a cronjob. I knew the cron environment was a bit different, but I didn't realize how much, or how to troubleshoot it effectively. Fixed: thornton2.com/unix/freebsd/sim

It turns out I needed `SHELL=/bin/sh` and `ENV=$HOME/.shrc` in my crontab and `PATH=` statements in my .shrc file. Oops.

And that tripped me up in some subtle ways. I actually needed `ENV=/home/arielmt/.shrc` instead, and to source it on cronjob lines. Now all my jobs are working properly & my crontab looks nice and neat. I updated the page I posted earlier because it was wrong. Double oops. :computerfairies:

Sign in to participate in the conversation
Computer Fairies

Computer Fairies is a Mastodon instance that aims to be as queer, friendly and furry as possible. We welcome all kinds of computer fairies!