You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
1 - Create supervisor configuration file (for ex., named `laravel-worker.conf`) for Laravel Queue Worker in `php-worker/supervisord.d/` by simply copy from `laravel-worker.conf.example`
536
+
558
537
2 - Start everything up
559
538
560
539
```bash
@@ -566,6 +545,34 @@ docker-compose up -d php-worker
566
545
567
546
568
547
548
+
<br>
549
+
<aname="Run-Laravel-Scheduler"></a>
550
+
## Run Laravel Scheduler
551
+
552
+
Laradock provides 2 ways to run Laravel Scheduler
553
+
1 - Using cron in workspace container. Most of the time, when you start Laradock, it'll automatically start workspace container with cron inside, along with setting to run `schedule:run` command every minute.
554
+
555
+
2 - Using Supervisord in php-worker to run `schedule:run`. This way is suggested when you don't want to start workspace in production environment.
556
+
<br>
557
+
a) Comment out cron setting in workspace container, file `workspace/crontab/laradock`
b) Create supervisor configuration file (for ex., named `laravel-scheduler.conf`) for Laravel Scheduler in `php-worker/supervisord.d/` by simply copy from `laravel-scheduler.conf.example`
564
+
<br>
565
+
c) Start php-worker container
566
+
567
+
```bash
568
+
docker-compose up -d php-worker
569
+
```
570
+
571
+
572
+
573
+
574
+
575
+
569
576
<br>
570
577
<aname="Use-Mailu"></a>
571
578
## Use Mailu
@@ -1198,7 +1205,7 @@ We also recommend [setting the timezone in Laravel](http://www.camroncade.com/ma
1198
1205
You can add your cron jobs to `workspace/crontab/root` after the `php artisan` line.
0 commit comments