mirror of
https://github.com/browseros-ai/BrowserOS.git
synced 2026-05-14 16:14:28 +00:00
feat: make dev commands easier to run (#311)
* feat: process compose * chore: run install on process compose * docs: updated README * chore: added agent-codegen step * docs: updated README
This commit is contained in:
18
README.md
18
README.md
@@ -72,15 +72,27 @@ packages/
|
||||
|
||||
### Setup
|
||||
|
||||
```bash
|
||||
# Install dependencies
|
||||
bun install
|
||||
Requires [process-compose](https://github.com/F1bonacc1/process-compose):
|
||||
|
||||
```bash
|
||||
brew install process-compose
|
||||
```
|
||||
|
||||
```bash
|
||||
# Copy environment files for each package
|
||||
cp apps/server/.env.example apps/server/.env.development
|
||||
cp apps/agent/.env.example apps/agent/.env.development
|
||||
|
||||
# Start the full dev environment
|
||||
process-compose up
|
||||
```
|
||||
|
||||
The `process-compose up` command runs the following in order:
|
||||
1. `bun install` — installs dependencies
|
||||
2. `bun --cwd apps/controller-ext build` — builds the controller extension
|
||||
3. `bun --cwd apps/agent codegen` — generates agent code
|
||||
4. `bun --cwd apps/server start` and `bun --cwd apps/agent dev` — starts server and agent in parallel
|
||||
|
||||
### Environment Variables
|
||||
|
||||
Each package has its own `.env.development` file:
|
||||
|
||||
2
bun.lock
2
bun.lock
@@ -138,7 +138,7 @@
|
||||
},
|
||||
"apps/server": {
|
||||
"name": "@browseros/server",
|
||||
"version": "0.0.51",
|
||||
"version": "0.0.52",
|
||||
"bin": {
|
||||
"browseros-server": "./src/index.ts",
|
||||
},
|
||||
|
||||
37
process-compose.yaml
Normal file
37
process-compose.yaml
Normal file
@@ -0,0 +1,37 @@
|
||||
version: "0.5"
|
||||
|
||||
processes:
|
||||
install:
|
||||
command: bun install
|
||||
availability:
|
||||
restart: no
|
||||
|
||||
build-ext:
|
||||
command: bun --cwd apps/controller-ext build
|
||||
availability:
|
||||
restart: no
|
||||
depends_on:
|
||||
install:
|
||||
condition: process_completed_successfully
|
||||
|
||||
server:
|
||||
command: bun --cwd apps/server start
|
||||
depends_on:
|
||||
build-ext:
|
||||
condition: process_completed_successfully
|
||||
|
||||
agent-codegen:
|
||||
command: bun --cwd apps/agent codegen
|
||||
availability:
|
||||
restart: no
|
||||
depends_on:
|
||||
install:
|
||||
condition: process_completed_successfully
|
||||
|
||||
agent:
|
||||
command: bun --cwd apps/agent dev
|
||||
depends_on:
|
||||
build-ext:
|
||||
condition: process_completed_successfully
|
||||
agent-codegen:
|
||||
condition: process_completed_successfully
|
||||
Reference in New Issue
Block a user