定制 zeevx/laravel-brimble-sandbox 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

zeevx/laravel-brimble-sandbox

Composer 安装命令:

composer require zeevx/laravel-brimble-sandbox

包简介

Laravel integration for the Brimble Sandbox PHP SDK: config, container binding, facade, and Artisan commands.

README 文档

README

Laravel integration for zeevx/php-brimble-sandbox: a config file, a container binding, a facade, and Artisan commands. All the API logic lives in the core package; this is the glue.

Install

composer require zeevx/laravel-brimble-sandbox

The service provider and BrimbleSandbox facade are auto-discovered. Publish the config if you want to tweak defaults:

php artisan vendor:publish --tag=brimble-sandbox-config

Configure

Set your key in .env:

BRIMBLE_SANDBOX_KEY=your-api-key

Optional overrides (shown with defaults):

BRIMBLE_SANDBOX_BASE_URL=https://sandbox.brimble.io
BRIMBLE_SANDBOX_TIMEOUT=90
BRIMBLE_SANDBOX_MAX_RETRIES=2

Usage

Resolve the client from the container, inject it, or use the facade. All three give you the same configured Zeevx\BrimbleSandbox\Sandbox instance.

use Zeevx\LaravelBrimbleSandbox\Facades\BrimbleSandbox;
use Zeevx\BrimbleSandbox\Requests\CreateSandbox;
use Zeevx\BrimbleSandbox\Requests\ExecInput;

$sb = BrimbleSandbox::sandboxes()->create(new CreateSandbox(template: 'node-22'));

echo $sb->exec(new ExecInput('node -v'))->stdout;

$sb->destroy();

Dependency injection:

use Zeevx\BrimbleSandbox\Sandbox;

public function __construct(private readonly Sandbox $brimble) {}

See the core package README for the full API (exec/code, streaming, files, snapshots, volumes, pagination, error handling).

Artisan commands

# List your sandboxes
php artisan brimble:sandbox:list --page=1 --limit=15

# Run a shell command inside a sandbox (add --stream for live output)
php artisan brimble:sandbox:exec {id} "npm test" --stream

# Destroy a sandbox (add --force to skip the prompt)
php artisan brimble:sandbox:destroy {id}

Development

composer test      # Pest + Testbench
composer lint      # Pint
composer analyse   # PHPStan (Larastan)

License

MIT

统计信息

  • 总下载量: 0
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2026-07-05

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固