My Tech Notes
Ubuntu: script works in terminal fails in cron
Solution:
initialize the environment variables by sourcing
/etc/bash.bashrc
before executing your script.
0 0 * * * source /etc/bash.bashrc; /path/to/yourscript.sh
No comments:
Post a Comment
‹
›
Home
View web version
No comments:
Post a Comment