I'm trying to run a casper.js script via cron. Everything works fine when I run the script manually, but when I run it via cron I get the following errors:
Traceback (most recent call last):
File "/usr/local/bin/casperjs", line 46, in <module>
status = subprocess.call(CASPER_COMMAND)
File "/usr/lib/python2.6/subprocess.py", line 480, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib/python2.6/subprocess.py", line 633, in __init__
errread, errwrite)
File "/usr/lib/python2.6/subprocess.py", line 1139, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
My crontab entry is:
30 9 * * * /usr/local/bin/casperjs lib/fsaupload.js arg1 arg2 arg3
I've also tried
30 9 * * * python /usr/local/bin/casperjs lib/fsaupload.js arg1 arg2 arg3
Which gives me the same result. Any ideas? I'm guessing it might be a path
issue, but no idea where to go from here!