Jump to:

23376 Posts in 18222 Topics by 2867 members

General Questions

SilverStripe Forums » General Questions » Getting DailyTask to work

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 1397 Views
  • Andrew Houle
    Avatar
    Community Member
    132 Posts

    Getting DailyTask to work Link to this post

    I have a simple function set up for a Daily Scheduled Task. It was difficult to find info on this topic, but I pieced together enough to get me real close. I know the task works because it tests ok when I run http://yourdomain.com/DailyTask

    I've setup a cron job that looks like this: */1 * * * * /usr/bin/php-cgi /path/to/my/site/sapphire/cli-script.php DailyTask I set it up for every minute just for testing purposes. The email log that I receive stats this, "Please specify an argument to cli-script.php/sake. For more information, visit http://doc.silverstripe.org/doku.php?id=sake" I tried setting up the _ss_environment.php file according to the info there and here - http://www.silverstripe.org/general-questions/show/260805#post260805 but to no success. My _ss_environment.php looks like this

    <?php
    global $_FILE_TO_URL_MAPPING;
    $_FILE_TO_URL_MAPPING['/path/to/my/site'] = 'http://mydomain.com';
    ?>

    I'm running low on ideas, any help would be very much appreciated.

    Thanks,
    Andrew

  • Andrew Houle
    Avatar
    Community Member
    132 Posts

    Re: Getting DailyTask to work Link to this post

    For completion sake, I got this to run thanks to some folks in the IRC with the following...

    */1 * * * * cd /path/to/my/site usr/bin/php-cgi && php sapphire/cli-script.php DailyTask

    I'm on php 5.1.x so that's why I think it was failing.

    1397 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.