Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Cloud Cli Laravel Package

laravel/cloud-cli

Laravel Zero-based CLI to deploy and manage apps on Laravel Cloud from your terminal. OAuth auth, repo linking via GitHub CLI, guided ship/deploy flows, and commands for apps, environments, databases, caches, storage, domains, and more.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture Fit

  • Laravel Ecosystem Alignment: The package is purpose-built for Laravel Cloud, ensuring native integration with Laravel’s deployment workflows (e.g., Forge, Vapor, or Cloud). It abstracts low-level API interactions, reducing boilerplate for teams already using Laravel’s ecosystem.
  • CLI-Driven DevOps: Fits seamlessly into CI/CD pipelines (e.g., GitHub Actions) where CLI tools are preferred over web dashboards. Complements existing Laravel tools like laravel-installer or laravel-shift.
  • Modularity: Commands are granular (e.g., cloud:app:create, cloud:env:deploy), allowing selective adoption without forcing full migration.

Integration Feasibility

  • Laravel Projects: Minimal friction for Laravel apps (PHP 8.2+ required). Existing Laravel projects can adopt this without architectural changes.
  • Non-Laravel Projects: Limited utility outside Laravel’s ecosystem (e.g., no direct support for Symfony or custom PHP apps). Requires Laravel-specific setup (e.g., composer.json dependencies).
  • GitHub Dependency: Hard dependency on gh CLI for OAuth and repo linking may complicate adoption in environments where GitHub CLI isn’t available or preferred (e.g., GitLab-centric teams).

Technical Risk

  • Authentication Complexity: OAuth flow and token management (~/.config/cloud/config.json) introduces security/permission risks if misconfigured (e.g., leaked tokens in CI). Requires clear documentation for CI/CD use cases.
  • Version Lock: Tied to Laravel Cloud’s API (last release 2026-04-03). Risk of breaking changes if Laravel Cloud’s API evolves without backward compatibility.
  • Local Development Overhead: Requires manual alias setup or global Composer install, which may not align with containerized or ephemeral dev environments.

Key Questions

  1. API Stability: How frequently does Laravel Cloud’s API change? Are there deprecation policies or versioned endpoints?
  2. CI/CD Integration: How does token management scale in multi-team environments (e.g., shared CI tokens vs. per-developer)?
  3. Alternatives: Would this replace existing tools (e.g., Laravel Forge CLI, Vapor CLI) or complement them? Are there overlaps in functionality?
  4. Error Handling: How are API failures (e.g., rate limits, OAuth errors) surfaced to users? Are retries/fallbacks implemented?
  5. Extensibility: Can the CLI be extended for custom Laravel Cloud features (e.g., webhooks, monitoring) without forking?

Integration Approach

Stack Fit

  • Primary Use Case: Ideal for Laravel teams using Laravel Cloud (especially those migrating from Forge/Vapor or adopting Cloud for the first time). Best fit for:
    • Backend Teams: Managing deployments, databases, and infrastructure via CLI.
    • DevOps/SREs: Automating repetitive tasks (e.g., environment provisioning) in scripts/pipelines.
  • Secondary Use Case: Limited value for frontend-only teams or projects not using Laravel Cloud.
  • Toolchain Synergy:
    • Complements: Laravel Sail, Forge, Vapor CLI, or Homestead for hybrid workflows.
    • Conflicts: May duplicate functionality with existing Laravel deployment tools (e.g., vapor deploy). Requires clear delineation of responsibilities.

Migration Path

  1. Pilot Phase:
    • Start with non-critical workflows (e.g., cloud:env:list, cloud:db:create) in a staging environment.
    • Test authentication in CI (e.g., GitHub Actions) using cloud auth:token with service accounts.
  2. Phased Adoption:
    • Phase 1: Replace manual dashboard interactions (e.g., environment scaling) with CLI commands.
    • Phase 2: Integrate into CI/CD (e.g., post-merge deployments via cloud:env:deploy).
    • Phase 3: Explore advanced use cases (e.g., dynamic database provisioning).
  3. Fallback Plan:
    • Maintain parallel access to Laravel Cloud’s web UI for critical operations during transition.
    • Document CLI limitations (e.g., no UI for visualizing logs) and workarounds.

Compatibility

  • PHP 8.2+: Ensure all team members and CI environments meet this requirement. May require upgrading older Laravel projects.
  • GitHub CLI: Evaluate if gh is already a team standard. If not, assess the effort to onboard it (e.g., brew install gh on macOS, apt-get install gh on Linux).
  • Laravel Cloud API: Verify no undocumented API changes since the last release (2026-04-03). Monitor Laravel Cloud’s changelog for breaking updates.
  • Shell Environment: Test alias setup across team members’ shells (Zsh, Bash, Fish) and CI runners (e.g., GitHub Actions uses Bash by default).

Sequencing

  1. Pre-requisites:
    • Upgrade PHP to 8.2+ in all environments.
    • Install and authenticate gh CLI for all developers.
    • Set up Laravel Cloud OAuth credentials for the team.
  2. Core Integration:
    • Install cloud-cli globally or via project alias.
    • Configure cloud repo:config for key projects.
    • Test authentication (cloud auth) and basic commands (cloud:app:list).
  3. CI/CD Integration:
    • Securely store API tokens in CI secrets (e.g., GitHub Secrets).
    • Add cloud:env:deploy to deployment pipelines.
  4. Advanced:
    • Automate database/cache provisioning via CLI.
    • Explore webhook integrations for event-driven workflows.

Operational Impact

Maintenance

  • Dependency Management:
    • Monitor composer.json for updates to laravel/cloud-cli and Laravel Cloud’s PHP SDK.
    • Pin versions in composer.lock for CI stability.
  • Configuration Drift:
    • Centralize ~/.config/cloud/config.json management (e.g., use a config management tool like Ansible for team-wide token sync).
    • Document token rotation policies (e.g., monthly rotation for CI tokens).
  • Deprecation:
    • Plan for Laravel Cloud API deprecations (e.g., if endpoints are removed, CLI may need forks or patches).

Support

  • Troubleshooting:
    • Common issues likely include:
      • OAuth failures (e.g., misconfigured gh CLI or browser redirects).
      • Permission errors (e.g., insufficient Laravel Cloud API scopes).
      • Command ambiguity (e.g., cloud:env:deploy vs. vapor deploy).
    • Mitigation: Create a runbook with:
      • Debug commands (e.g., cloud --verbose).
      • Steps to regenerate tokens (cloud auth:token --force).
      • Fallback to web UI for unsupported operations.
  • Documentation Gaps:
    • Clarify edge cases (e.g., multi-repo setups, shared environments).
    • Example: Add a CI_CD_GUIDE.md with token management best practices.

Scaling

  • Performance:
    • CLI commands are likely I/O-bound (API calls). Test with large environments (e.g., 50+ databases) to identify latency.
    • Cache API responses in CI for repeated operations (e.g., cloud:env:list).
  • Team Adoption:
    • Onboarding: Create a 15-minute tutorial video for developers unfamiliar with CLI tools.
    • Incentives: Highlight time savings (e.g., "Deploy in 1 command vs. 5 dashboard clicks").
    • Resistance: Address concerns about "another CLI to learn" by mapping commands to existing workflows.
  • Multi-Cloud/Team:
    • Support for multiple Laravel Cloud accounts requires explicit context switching (e.g., --account-id flags). Document this early.

Failure Modes

Failure Scenario Impact Mitigation
OAuth token expiration Broken CI/CD pipelines Automate token refresh via cloud auth:token.
Laravel Cloud API outage Unavailable deployments Implement retry logic with exponential backoff.
Misconfigured gh CLI Authentication failures Validate gh auth status in CI pre-steps.
Permission errors (e.g., no DB access) Deployments blocked Audit Laravel Cloud API scopes and roles.
Shell alias issues CLI inaccessible Use global Composer install as fallback.
API rate limits Slow operations Add rate-limit headers or implement caching.

Ramp-Up

  • Training:
    • Workshop: 1-hour session covering:
      • Authentication (cloud auth).
      • Core commands (cloud:env:deploy, cloud:db:create).
      • CI/CD integration.
    • Cheat Sheet: Printable reference for commands, flags, and examples.
  • Feedback Loop:
    • Collect pain points via a shared doc (e.g., "What
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
milesj/emojibase
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport