Basically the commands in the CRONTAB will be executed from the root folder.
In-order to execute something with CARTON we are suppose to be in the directory where cpanfile resides.
I have tried CD (change directory) to the cpanfile directory and run the script.sh manually- it is working fine.
but, when i schedule the same script.sh in CRONTAB it is throwing error 'carton: command not found'
here is my script.sh
--------------------------------
#!/bin/bash
cd Desktop/projectFolder/
carton exec perl script/
run.pl----------------------------------
And my cpanfile is in the directory 'projectFolder'
Thanks in advance.