- How do I install dragon-code/laravel-deploy-operations in a Laravel project?
- Install it with Composer using composer require dragon-code/laravel-deploy-operations, then publish the package configuration and define the operations your deploy should run. Wire the package command into your existing deployment pipeline rather than calling it from application routes or schedules. Check the README for the exact publish command and required Laravel version constraints before rolling it out.
- Which Laravel versions does laravel-deploy-operations support?
- The supported Laravel and PHP versions are declared in the package composer.json, so review those constraints before adding it to an existing application. Because the 7.3.0 release adds queue job dispatch and lock-related config, test it against your target Laravel major and queue driver. If you are on an older Laravel version, pin the package release that matches your framework constraints.
- How do I define deployment operations such as migrations and cache clearing?
- Operations are defined in the package configuration and executed during the deploy step, so you can list migrations, cache clears, queue restarts, and other repeatable tasks in one place. Keep the list ordered the way your release needs, especially around config:cache and route:cache. Commit the configuration so every environment runs the same operations.
- Can I run custom Artisan commands during a deployment with this package?
- Yes. The package is designed to run Artisan commands as part of the deployment operation list, alongside built-in tasks like migrations and cache clearing. Use this for application-specific warmup or cleanup commands that must happen on every release. Keep custom commands idempotent because deploy steps can be retried or run in overlapping pipelines.
- Does laravel-deploy-operations support queued deployment operations?
- Version 7.3.0 adds queue-related configuration, including a queue.job override and lock duration, which means operations can be dispatched as queued jobs. That introduces a worker-side component and requires a queue connection, worker, and restart-on-deploy step. If you only need synchronous deploy tasks, scope the queue path out and keep the console-only workflow.
- How does the queue lock duration affect deployment operations?
- The configurable lock duration controls how long an isolated or overlapping deployment operation is considered locked. Set it longer than the expected operation runtime but short enough that a failed run does not block later deploys with a phantom lock. Align it with your retry window and monitor for double execution or stalled releases after changing it.
- How do I integrate laravel-deploy-operations into a CI/CD pipeline?
- Run the package command as a dedicated deployment step after code is released and dependencies are installed, before traffic is switched or workers are restarted as needed. Avoid invoking it from web routes or the scheduler. Make sure configuration is present before config:cache runs and that storage permissions are correct, since those are common deployment failure points.
- How should I test laravel-deploy-operations before using it in production?
- Run a proof of concept in a staging pipeline that mirrors your production deploy order, including config:cache, route:cache, storage permissions, and queue restarts. Test both the console path and, if enabled, the queued path with your actual queue driver and worker configuration. Then pin the package version your platform team has reviewed before production rollout.
- Is dragon-code/laravel-deploy-operations actively maintained?
- The 7.3.0 release is a positive maintenance signal, including community-contributed changes, but it is not the same as broad production adoption. Review the repository's release history, open issues, and contributor activity before depending on it. For critical deployments, keep a fallback plan such as equivalent Artisan commands in your pipeline.
- What are alternatives to laravel-deploy-operations for running deploy tasks?
- Many teams use raw Artisan commands in their CI/CD scripts, Laravel Envoyer or Forge deployment hooks, or dedicated deployment tools to run migrations and cache clears. This package's value is centralizing those operations in configuration so releases are consistent and repeatable. Compare it with your existing pipeline before adding another dependency, especially if you do not need queued operations.