Announcement

Collapse
No announcement yet.

how do I add Scheduled Jobs to Crontab/Scheduled Tasks?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #16
    Hi, I need some help to setup cron tasks. The problem is, that I can do it only from my Cpanel on the shared server, by choosing menu cron jobs (as you can see in enclosed image). I filled the field with cron url, which I thionh shoud be correct 'http://mydomain/espo/cron.php' but it doesn't work. How shoud I setup cron task in my case?

    many thanks
    Click image for larger version

Name:	cronjob.png
Views:	546
Size:	35.1 KB
ID:	31059

    Comment


    • #17

      Comment


      • #18
        Hi, How can i call getMailSender() from "\Espo\Services\Email" in my custom cron job. when I extends "\Espo\Services\Email" it gives me " Espo.ERROR: Uncaught Exception Error: "Call to a member function getScopeRestrictedAttributeList() on null" at /var/www/html/EspoEspoLatest/application/Espo/Services/Record.php line 155 {"exception":"[object] (Error(code: 0): Call to a member function getScopeRestrictedAttributeList() on null at /var/www/html/EspoEspoLatest/application/Espo/Services/Record.php:155)"}" error.
        and when i create "\Espo\Services\Email" object and then call getMailSender(), it gives me you can't call protected method error.

        Please help me out, I haven't found anything for this
        Last edited by swati; 06-11-2019, 09:35 AM.

        Comment


        • #19
          how can i set up cron job to execute a URL ?
          I set my URL like "0 10 * * * curl -s "url..." > /dev/null" in "sudo crontab -u www-data -e" at end of the file But this is not working.

          Comment

          Working...
          X