# Proper cron job setup for GoDaddy

**URL:** <https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469>\
**Category:** Product Support\
**Created:** [July 20, 2015, 9:46pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469 "2015-07-20T21:46:36Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![ChrisMorley](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@ChrisMorley](https://forum.mautic.org/u/ChrisMorley)\
**Post date:** [July 20, 2015, 9:46pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/1 "2015-07-20T21:46:36Z")

</div>

I’m on GoDaddy shared hosting. I’ve tried all sorts of formats but keep getting this: Could not open input file: /xxx/public\_html/mautic/app/console mautic:email:process --env=prod  
  
  
  
Could someone tell me the appropriate script I need to run? Here’s an example of one that failed: /usr/local/bin/php -q “$home/xxx/public\_html/mautic/app/console mautic:leadlists:update --env=prod”

---

<div class="post-metadata">

**Author:** ![ChrisMorley](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@ChrisMorley](https://forum.mautic.org/u/ChrisMorley)\
**Post date:** [July 21, 2015, 1:16pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/2 "2015-07-21T13:16:17Z")

</div>

Thanks, I’m going to get in touch with them now, appreciate it!

---

<div class="post-metadata">

**Author:** ![ChrisMorley](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@ChrisMorley](https://forum.mautic.org/u/ChrisMorley)\
**Post date:** [July 21, 2015, 1:34pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/3 "2015-07-21T13:34:41Z")

</div>

php /home/xxx/public\_html/mautic/app/console mautic:leadlists:update --env=prod ended up working for me. I cannot for the life of me figured out how I managed to screw that up. Thank you for your patience!

---

<div class="post-metadata">

**Author:** ![wootme](https://avatars.discourse-cdn.com/v4/letter/w/e9bcb4/32.png) [@wootme](https://forum.mautic.org/u/wootme)\
**Post date:** [July 21, 2015, 5:52am UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/4 "2015-07-21T05:52:30Z")

</div>

Proper format should be , just copy paste the below line in cron jobs.  
Below are the setting used in godaddy by me on a test machine:  
php /home/xxx/public\_html/mautic/app/console mautic:leadlists:update --env=prod

This one used in namecheap:  
php /usr/local/bin/php /home/xxx/public\_html/mautic/app/console mautic:leadlists:update --env=prod

Please make sure you are adding php in front, and try without -q.  
If all fails check with godaddy customer support, it could be the fact that “enhanced security” option might be checked.

---

<div class="post-metadata">

**Author:** ![ChrisMorley](https://avatars.discourse-cdn.com/v4/letter/c/9fc348/32.png) [@ChrisMorley](https://forum.mautic.org/u/ChrisMorley)\
**Post date:** [July 20, 2015, 9:46pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/5 "2015-07-20T21:46:36Z")

</div>

I’m on GoDaddy shared hosting. I’ve tried all sorts of formats but keep getting this: Could not open input file: /xxx/public\_html/mautic/app/console mautic:email:process --env=prod

Could someone tell me the appropriate script I need to run? Here’s an example of one that failed: /usr/local/bin/php -q “$home/xxx/public\_html/mautic/app/console mautic:leadlists:update --env=prod”

---

<div class="post-metadata">

**Author:** ![andrewchildsza](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/andrewchildsza/32/33_2.png) [@andrewchildsza](https://forum.mautic.org/u/andrewchildsza)\
**Post date:** [January 26, 2016, 2:59pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/6 "2016-01-26T14:59:42Z")

</div>

Hello!

I am getting a 500 error when I try and add the cron to my Namecheap cPanel.

Here is the error:  
PHP Parse error: syntax error, unexpected ‘{’ in /opt/alt/php56/usr/bin/php on line 2265  
Status: 500 Internal Server Error  
X-Powered-By: PHP/5.6.17  
Content-type: text/html; charset=UTF-8

Here is my cron entry:  
php /usr/local/bin/php /home/xxx/public\_html/mautic/app/console mautic:leadlists:update --env=prod

I’m running 1.2.4.

I’d love some help!

---

<div class="post-metadata">

**Author:** ![silavapi](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.mautic.org/silavapi/32/7424_2.png) [@silavapi](https://forum.mautic.org/u/silavapi)\
**Post date:** [February 2, 2020, 10:59pm UTC](https://forum.mautic.org/t/proper-cron-job-setup-for-godaddy/1469/7 "2020-02-02T22:59:09Z")

</div>


