Description
Performing any actions during the deployment process.
Create your first operation using php artisan make:operation console command and define the actions it should
perform.
use App\Models\Article;use DragonCode\LaravelDeployOperations\Operation; return new class extends Operation { public function __invoke(): void { Article::query() ->lazyById(chunkSize: 100, column: 'id') ->each->update(['is_active' => true]); // and/or any actions... }};
Next, you can run the console command to start operations:
php artisan operations
Recent Courses on Laravel Daily
[NEW] Laravel MCP Server: Practical SaaS Example
9 lessons
49 min
Laravel Boost: Deeper Practical Dive
8 lessons
32 min
Roles and Permissions in Laravel 13
14 lessons
57 min