How Do I execute a .sh script using cpanel cron job

User1984 59 Rep.

I am new to command line so please forgive my ignorance. I can successfully execute my script using SSH by navigating to the relevant directory and typing following command:


I’m now trying to set this script to run using cPanel cron job. I have tried the following but it doesn’t work:

* * * * * /public_html/app/cron_jobs/

Any help would be appreciated..

Kailash selected answer

Best answer

Kailash 152 Rep.

First, you will have to make sure that your script has execute permissions and then set following cron:

0 * * * * /home/<your_user>/public_html/

Adjust time as per your need.

User1984 commented on answer


Login to see your profile links
Bloom Email Optin Plugin