Cron jobs run only one time

epiz_28493722 http://poorbirds.rf.dg

http://poorbirds.rf.dg

Error Message

I have project on laravel. It uses schedule and cron. On my local machine i use (i have linux) crontab -e. I put in there php /var/www/poorbirds.com/artisan schedule:run >> /dev/null 2>&1.

In infinityfree i can’t do it. I need isert URL instead comand. In web.php i put this code

 Route::get('/cron/collect_eggs', function () {
     Artisan::call('collect:eggs');
 });

In the field Run the script http://poorbirds.rf.gd/ I put cron/collect_eggs. And in the field every minuts I chose 2.

After 2 minutes, this script runs, and then does not run again. Thet is, the script runs only once.
And I think it’s not safe, because everybody can go to /cron/collect_eggs.

Other Information

Is the cron job still there in the cron jobs page? There is a time limit to how long cron jobs can run. If they exceed the time limit, they are removed.

Yes, it is still there.

I need to run script every hour (every 1-2 minuts for tests)

Choose 1 hour and 2 minutes, the cron jobs is working weird here.

Ok, i will try. But i try to choose 0 hour 2 minutes

It do not work yet

@ColorKat, did u read?

2 Likes

I am sorry but what am I supposed to read exactly? Like I said before the cron job is bugged, it only works with a few of chosen values, If the OP is using cloudflare (seeing you don’t you should get a new domain and setup cloudflare on it), he can use some third party tool like

Hi @anon19508339, I wasn’t refering to u…

1 Like

i did it. It don’t work

I think, I buy iFastNet, because this server is very weak for my project

Just to double-check, you did do 1hr 2min right?

Yes, i did

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.