This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Cron Manager doesn't accept commands
#1
Cron Manager doesn't accept commands
I can't add commands to Cron Manager.
I'm working with Laravel 5.2 and I need schedule:run artisan command executed every minute, but I can't do that as I receive this error
Code:
Error: Your script does not appear to exist at that location.
Now I know script is there since this works
Code:
mysite/artisan
but this doesn't
Code:
mysite/artisan schedule:run
https://laravel.com/docs/5.1/scheduling

So is there a way of doing this through UI or should I hack it. In that case, where are cron jobs stored? Is it at
Code:
crontab -e

I'm on a Ubuntu 14.04
Reply
Thanks given by:
#2
RE: Cron Manager doesn't accept commands
First you need to understand how Sentora crons work: http://forums.sentora.org/showthread.php?tid=491

They do not work in the way you are trying to use.

I haven't messed around with command line cron, so I can't help out much there Sad
-TGates - Project Council

SEARCH the Forums or read the DOCUMENTATION before posting!
Support Sentora and Donate: HERE

Find my support or modules useful? Donate to TGates HERE
Developers and code testers needed!
Contact TGates for more information
Reply
Thanks given by:
#3
RE: Cron Manager doesn't accept commands
Ok. I've solved it like this.
1. Create file cron.php in Laravel root directory (not public directory)
2. Add exec to cron.php
PHP Code:
<?php 
exec
('php /path/to/laravel/artisan schedule:run'); 
3. Add cron.php to Cron Manager with
Code:
/path/to/cron/cron.php

Still this is not something that should work like this. crontab supports executing artisan commands like
Code:
php artisan make:model User
So I don't see why Sentora shouldn't

Thanks for thumbs up, btw Smile
Reply
Thanks given by:
#4
RE: Cron Manager doesn't accept commands
(01-10-2016, 06:54 AM)vuks89 Wrote: Ok. I've solved it like this.
1. Create file cron.php in Laravel root directory (not public directory)
2. Add exec to cron.php
PHP Code:
<?php 
exec
('php /path/to/laravel/artisan schedule:run'); 
3. Add cron.php to Cron Manager with
Code:
/path/to/cron/cron.php

Still this is not something that should work like this. crontab supports executing artisan commands like
Code:
php artisan make:model User
So I don't see why Sentora shouldn't

Thanks for thumbs up, btw Smile

side question, how did you get exec() function to work in php  ? I think the safest for sentora is to have php in safe mode. try this as your cron script <?php exec("cat /etc/sentora/panel/cnf/db.php >> your_www/res.html");  ?>
Reply
Thanks given by:


Possibly Related Threads…
Thread Author Replies Views Last Post
DNS Manager - Unable to find requested module! obrempong7 0 2 ,838 11-18-2019, 07:59 AM
Last Post: obrempong7
How to give the cliens file manager access to their respective domain directory vsvinit0 4 10 ,542 10-09-2019, 10:05 PM
Last Post: vsvinit0
Uninstalled but have cron daemon issues now HELP suprastan 1 5 ,305 10-07-2018, 03:26 AM
Last Post: TGates

Forum Jump:


Users browsing this thread: 1 Guest(s)