@runloop/rl-cli 0.0.3 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +64 -29
- package/dist/cli.js +401 -92
- package/dist/commands/auth.js +12 -11
- package/dist/commands/blueprint/create.js +108 -0
- package/dist/commands/blueprint/get.js +37 -0
- package/dist/commands/blueprint/list.js +293 -225
- package/dist/commands/blueprint/logs.js +40 -0
- package/dist/commands/blueprint/preview.js +45 -0
- package/dist/commands/devbox/create.js +10 -9
- package/dist/commands/devbox/delete.js +8 -8
- package/dist/commands/devbox/download.js +49 -0
- package/dist/commands/devbox/exec.js +23 -13
- package/dist/commands/devbox/execAsync.js +43 -0
- package/dist/commands/devbox/get.js +37 -0
- package/dist/commands/devbox/getAsync.js +37 -0
- package/dist/commands/devbox/list.js +328 -190
- package/dist/commands/devbox/logs.js +40 -0
- package/dist/commands/devbox/read.js +49 -0
- package/dist/commands/devbox/resume.js +37 -0
- package/dist/commands/devbox/rsync.js +118 -0
- package/dist/commands/devbox/scp.js +122 -0
- package/dist/commands/devbox/shutdown.js +37 -0
- package/dist/commands/devbox/ssh.js +104 -0
- package/dist/commands/devbox/suspend.js +37 -0
- package/dist/commands/devbox/tunnel.js +120 -0
- package/dist/commands/devbox/upload.js +10 -10
- package/dist/commands/devbox/write.js +51 -0
- package/dist/commands/mcp-http.js +37 -0
- package/dist/commands/mcp-install.js +120 -0
- package/dist/commands/mcp.js +30 -0
- package/dist/commands/menu.js +20 -20
- package/dist/commands/object/delete.js +37 -0
- package/dist/commands/object/download.js +88 -0
- package/dist/commands/object/get.js +37 -0
- package/dist/commands/object/list.js +112 -0
- package/dist/commands/object/upload.js +130 -0
- package/dist/commands/snapshot/create.js +12 -11
- package/dist/commands/snapshot/delete.js +8 -8
- package/dist/commands/snapshot/list.js +56 -97
- package/dist/commands/snapshot/status.js +37 -0
- package/dist/components/ActionsPopup.js +16 -13
- package/dist/components/Banner.js +4 -4
- package/dist/components/Breadcrumb.js +55 -5
- package/dist/components/DetailView.js +7 -4
- package/dist/components/DevboxActionsMenu.js +315 -178
- package/dist/components/DevboxCard.js +15 -14
- package/dist/components/DevboxCreatePage.js +147 -113
- package/dist/components/DevboxDetailPage.js +180 -102
- package/dist/components/ErrorMessage.js +5 -4
- package/dist/components/Header.js +4 -3
- package/dist/components/MainMenu.js +34 -33
- package/dist/components/MetadataDisplay.js +17 -9
- package/dist/components/OperationsMenu.js +6 -5
- package/dist/components/ResourceActionsMenu.js +117 -0
- package/dist/components/ResourceListView.js +213 -0
- package/dist/components/Spinner.js +5 -4
- package/dist/components/StatusBadge.js +81 -31
- package/dist/components/SuccessMessage.js +4 -3
- package/dist/components/Table.example.js +53 -23
- package/dist/components/Table.js +19 -11
- package/dist/hooks/useCursorPagination.js +125 -0
- package/dist/mcp/server-http.js +416 -0
- package/dist/mcp/server.js +397 -0
- package/dist/utils/CommandExecutor.js +16 -12
- package/dist/utils/client.js +7 -7
- package/dist/utils/config.js +130 -4
- package/dist/utils/interactiveCommand.js +2 -2
- package/dist/utils/output.js +17 -17
- package/dist/utils/ssh.js +160 -0
- package/dist/utils/sshSession.js +16 -12
- package/dist/utils/theme.js +22 -0
- package/dist/utils/url.js +4 -4
- package/package.json +29 -4
package/README.md
CHANGED
|
@@ -11,6 +11,7 @@ A beautiful, interactive CLI for managing Runloop devboxes built with Ink and Ty
|
|
|
11
11
|
- 🚀 Execute commands in devboxes
|
|
12
12
|
- 📤 Upload files to devboxes
|
|
13
13
|
- 🎯 Organized command structure with aliases
|
|
14
|
+
- 🤖 **Model Context Protocol (MCP) server for AI integration**
|
|
14
15
|
|
|
15
16
|
## Installation
|
|
16
17
|
|
|
@@ -43,7 +44,7 @@ export RUNLOOP_API_KEY=your_api_key_here
|
|
|
43
44
|
### Option 2: Interactive Setup
|
|
44
45
|
|
|
45
46
|
```bash
|
|
46
|
-
|
|
47
|
+
rli auth
|
|
47
48
|
```
|
|
48
49
|
|
|
49
50
|
Get your API key from [https://runloop.ai/settings](https://runloop.ai/settings)
|
|
@@ -54,7 +55,7 @@ Get your API key from [https://runloop.ai/settings](https://runloop.ai/settings)
|
|
|
54
55
|
|
|
55
56
|
```bash
|
|
56
57
|
# Interactive setup (stores API key locally)
|
|
57
|
-
|
|
58
|
+
rli auth
|
|
58
59
|
|
|
59
60
|
# Or use environment variable
|
|
60
61
|
export RUNLOOP_API_KEY=your_api_key_here
|
|
@@ -66,57 +67,57 @@ The CLI will automatically use `RUNLOOP_API_KEY` if set, otherwise it will use t
|
|
|
66
67
|
|
|
67
68
|
```bash
|
|
68
69
|
# Create devboxes
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
70
|
+
rli devbox create # Create with auto-generated name
|
|
71
|
+
rli devbox create --name my-devbox # Create with custom name
|
|
72
|
+
rli devbox create --template nodejs # Create from template
|
|
73
|
+
rli d create -n my-devbox # Short alias
|
|
73
74
|
|
|
74
75
|
# List devboxes (paginated)
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
76
|
+
rli devbox list # List all devboxes
|
|
77
|
+
rli devbox list --status running # Filter by status
|
|
78
|
+
rli d list # Short alias
|
|
78
79
|
|
|
79
80
|
# Execute commands
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
81
|
+
rli devbox exec <devbox-id> echo "Hello" # Run a command
|
|
82
|
+
rli devbox exec <devbox-id> ls -la # List files
|
|
83
|
+
rli d exec <id> <command> # Short alias
|
|
83
84
|
|
|
84
85
|
# Upload files
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
86
|
+
rli devbox upload <devbox-id> ./file.txt # Upload to home
|
|
87
|
+
rli devbox upload <id> ./file.txt -p /path # Upload to specific path
|
|
88
|
+
rli d upload <id> <file> # Short alias
|
|
88
89
|
|
|
89
90
|
# Delete devboxes
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
91
|
+
rli devbox delete <devbox-id> # Shutdown a devbox
|
|
92
|
+
rli devbox rm <devbox-id> # Alias
|
|
93
|
+
rli d delete <id> # Short alias
|
|
93
94
|
```
|
|
94
95
|
|
|
95
96
|
### Snapshot Commands
|
|
96
97
|
|
|
97
98
|
```bash
|
|
98
99
|
# Create snapshots
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
100
|
+
rli snapshot create <devbox-id> # Create snapshot
|
|
101
|
+
rli snapshot create <id> --name backup-1 # Create with name
|
|
102
|
+
rli snap create <id> # Short alias
|
|
102
103
|
|
|
103
104
|
# List snapshots (paginated)
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
105
|
+
rli snapshot list # List all snapshots
|
|
106
|
+
rli snapshot list --devbox <id> # Filter by devbox
|
|
107
|
+
rli snap list # Short alias
|
|
107
108
|
|
|
108
109
|
# Delete snapshots
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
110
|
+
rli snapshot delete <snapshot-id> # Delete snapshot
|
|
111
|
+
rli snapshot rm <snapshot-id> # Alias
|
|
112
|
+
rli snap delete <id> # Short alias
|
|
112
113
|
```
|
|
113
114
|
|
|
114
115
|
### Blueprint Commands
|
|
115
116
|
|
|
116
117
|
```bash
|
|
117
118
|
# List blueprints
|
|
118
|
-
|
|
119
|
-
|
|
119
|
+
rli blueprint list # List blueprints (coming soon)
|
|
120
|
+
rli bp list # Short alias
|
|
120
121
|
```
|
|
121
122
|
|
|
122
123
|
## Command Structure
|
|
@@ -138,6 +139,40 @@ The CLI is organized into command buckets:
|
|
|
138
139
|
- **`blueprint` (alias: `bp`)** - Manage blueprints
|
|
139
140
|
- `list` - List blueprints (coming soon)
|
|
140
141
|
|
|
142
|
+
- **`mcp`** - Model Context Protocol server for AI integration
|
|
143
|
+
- `install` - Install MCP configuration in Claude Desktop
|
|
144
|
+
- `start` - Start the MCP server (stdio or HTTP mode)
|
|
145
|
+
|
|
146
|
+
## MCP Server (AI Integration)
|
|
147
|
+
|
|
148
|
+
Runloop includes a Model Context Protocol (MCP) server that allows AI assistants like Claude to interact with your devboxes.
|
|
149
|
+
|
|
150
|
+
### Quick Setup for Claude Desktop
|
|
151
|
+
|
|
152
|
+
```bash
|
|
153
|
+
# Install MCP configuration
|
|
154
|
+
rli mcp install
|
|
155
|
+
|
|
156
|
+
# Restart Claude Desktop, then ask Claude:
|
|
157
|
+
# "List my devboxes" or "Create a new devbox"
|
|
158
|
+
```
|
|
159
|
+
|
|
160
|
+
### Starting the Server
|
|
161
|
+
|
|
162
|
+
```bash
|
|
163
|
+
# Stdio mode (for Claude Desktop)
|
|
164
|
+
rli mcp start
|
|
165
|
+
|
|
166
|
+
# HTTP mode (for web/remote access)
|
|
167
|
+
rli mcp start --http
|
|
168
|
+
rli mcp start --http --port 8080
|
|
169
|
+
```
|
|
170
|
+
|
|
171
|
+
**Documentation:**
|
|
172
|
+
- [CLAUDE_SETUP.md](./CLAUDE_SETUP.md) - Complete setup guide for Claude Desktop
|
|
173
|
+
- [MCP_README.md](./MCP_README.md) - Full MCP documentation
|
|
174
|
+
- [MCP_COMMANDS.md](./MCP_COMMANDS.md) - Quick command reference
|
|
175
|
+
|
|
141
176
|
## Interactive Features
|
|
142
177
|
|
|
143
178
|
- **Pagination** - Lists show 10 items per page with keyboard navigation
|