Reputation: 439
I'm trying to figure out a way I can set a artisan command to run in the background when a user does an action, if I run the artisan call method the browser will just load untill it's done.
What I want to do is would similar this to in the terminal:
php artisan fix > /dev/null 2>&1 &
But run it from the controller instead, is that possible?
Btw. I know I could just setup a cronjob to run it, but I really want to run it from the controller.
Upvotes: 3
Views: 4606