mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-05-30 23:44:33 -04:00
INA-5 | TaskScheduler Job [WIP]
This commit is contained in:
parent
131cacd47f
commit
753978fe86
@ -19,6 +19,7 @@ use App\Jobs\Ledger\LedgerBalanceUpdate;
|
||||
use App\Jobs\Ninja\AdjustEmailQuota;
|
||||
use App\Jobs\Ninja\CompanySizeCheck;
|
||||
use App\Jobs\Ninja\QueueSize;
|
||||
use App\Jobs\Ninja\TaskScheduler;
|
||||
use App\Jobs\Util\DiskCleanup;
|
||||
use App\Jobs\Util\ReminderJob;
|
||||
use App\Jobs\Util\SchedulerCheck;
|
||||
@ -73,8 +74,9 @@ class Kernel extends ConsoleKernel
|
||||
|
||||
$schedule->job(new SchedulerCheck)->daily()->withoutOverlapping();
|
||||
|
||||
if(Ninja::isSelfHost())
|
||||
{
|
||||
$schedule->job(new TaskScheduler())->daily()->withoutOverlapping();
|
||||
|
||||
if (Ninja::isSelfHost()) {
|
||||
|
||||
$schedule->call(function () {
|
||||
Account::whereNotNull('id')->update(['is_scheduler_running' => true]);
|
||||
@ -97,7 +99,7 @@ class Kernel extends ConsoleKernel
|
||||
|
||||
}
|
||||
|
||||
if(config('queue.default') == 'database' && Ninja::isSelfHost() && config('ninja.internal_queue_enabled') && !config('ninja.is_docker')) {
|
||||
if (config('queue.default') == 'database' && Ninja::isSelfHost() && config('ninja.internal_queue_enabled') && !config('ninja.is_docker')) {
|
||||
|
||||
$schedule->command('queue:work database --stop-when-empty')->everyMinute()->withoutOverlapping();
|
||||
|
||||
@ -114,7 +116,7 @@ class Kernel extends ConsoleKernel
|
||||
*/
|
||||
protected function commands()
|
||||
{
|
||||
$this->load(__DIR__.'/Commands');
|
||||
$this->load(__DIR__ . '/Commands');
|
||||
|
||||
require base_path('routes/console.php');
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user