What is the Laravel Cloud CLI?
laravel/cloud-cli is a CLI for operating Laravel Cloud from your terminal.
Built on Laravel Zero, it lets you run the same operations you would perform in the dashboard using the cloud command.
With this CLI, you can centrally manage applications, environments, databases, caches, buckets, domains, WebSockets, and more.
Requirements
Before installing, make sure the following are in place:PHP 8.2+ComposerGitHub CLI (gh)(installed and authenticated)Git
Installation
First, set up the CLI locally.1
Clone the repository and install dependencies
2
Set up a `cloud` alias
zsh:bash:
3
Manual setup with an arbitrary path
Authentication
Authenticate before using most commands.cloud auth opens the browser and authenticates via OAuth.
If you want to manage tokens for CI or similar, use cloud auth:token.
Repository configuration
If you don’t want to choose theapplication or environment every time in your project, run cloud repo:config.
cloud deploy with fewer arguments.
Deployment
It’s efficient to distinguish between the initial deploy and subsequent deploys.Main command categories
From the command reference in the README, here are the categories you’ll use daily.Environment variable management
Manage environment variables withcloud environment:variables.
This command handles operations such as append / set / replace together.
Checking usage
Check billing and resource usage withcloud usage.
cloud usage --environment=<id>.