laravel/forge-cli
Laravel Forge CLI is the command-line companion for Laravel Forge, letting you provision servers, deploy sites, and manage scheduled jobs, queue workers, and SSL certificates from your terminal.
forge-cli + Forge is hand-rolled deploy scripts, Deployer, GitHub Actions pipelines, or a container platform. The CLI's value is that it removes bespoke scripting for routine operations: deploy, tail deployment and daemon logs, pull/push environment files, open a database shell, configure SSH, and script deploys from CI using FORGE_API_TOKEN (non-interactive use has explicit support).ssh:configure, server:list, site:list with tags, and open shorten time-to-first-deploy for new engineers and give the team one documented interface instead of per-engineer SSH habits.env:pull / env:push and scriptable deploys make it practical to keep local, staging, and production configuration aligned, and to trigger deploys from a pipeline rather than a dashboard click — an auditable, repeatable change to the release process.deploy:logs showing stale logs, custom SSH port handling. That tells you where teams actually feel friction (deploy observability, long-running deploys, non-standard networking) — useful when prioritizing internal platform work.Consider it when:
FORGE_API_TOKEN and no interactive prompts.Look elsewhere when:
.env movement through a third-party API is not acceptable without an approved handling policy.To executives: This is a free, MIT-licensed command-line tool from the Laravel team that automates deploys and server operations for apps we already host on Laravel Forge. It costs nothing to adopt beyond the Forge subscription we already pay for, and it reduces manual dashboard work and deploy mistakes. The trade-off is vendor concentration: our release automation would depend on Forge's API, which has already forced one major upgrade. Recommendation: adopt within the Forge footprint, keep the scope to deploys, logs, and environment sync, and avoid making it a hard dependency in anything we could not migrate within a sprint.
To engineering: Install the CLI, authenticate with a scoped Forge API token (or FORGE_API_TOKEN in CI), and use it for deploys, log tailing, env:pull/env:push, ssh:configure, and database shell access. It is a CLI wrapper, not a library — script it, don't import it. Practical cautions: treat env:push as a production write, pin the CLI version in CI, and set explicit deploy poll interval/timeout values rather than relying on defaults. It is actively maintained (Dependabot, hardened GitHub Actions, regular patches), but adoption breadth is modest (~246 stars), so expect to validate edge cases like custom SSH ports and non-interactive environments yourself rather than relying on community answers.
Ask: approve a time-boxed pilot on one non-critical service, with a documented fallback to existing deploy scripts, before standardizing across the Forge estate.
How can I help you explore Laravel packages today?