-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
63 lines (54 loc) · 2.08 KB
/
Copy pathMakefile
File metadata and controls
63 lines (54 loc) · 2.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
.PHONY: setup dev backend frontend test lint clean help
## Default: show help
help:
@echo "AgentOrch — AI Agent Orchestration Platform"
@echo ""
@echo " make setup Install all dependencies and initialize the database"
@echo " make dev Start all services for local development"
@echo " make backend Start only the FastAPI backend (hot reload)"
@echo " make frontend Start only the Next.js frontend"
@echo " make test Run the full test suite"
@echo " make lint Run ruff + tsc type checks"
@echo " make docker Start everything via Docker Compose"
@echo " make clean Remove virtual envs, node_modules, and build artifacts"
## Full setup from scratch
setup:
@echo "→ Setting up AgentOrch..."
@cp -n .env.example .env 2>/dev/null || true
@echo "→ Backend: creating venv and installing deps..."
cd backend && python3.11 -m venv .venv && .venv/bin/pip install --quiet -r requirements.txt
@echo "→ Backend: initializing database..."
backend/.venv/bin/python -c "import asyncio; from backend.database import init_db; asyncio.run(init_db())"
@echo "→ Frontend: installing Node deps..."
cd frontend && npm install --silent
@echo ""
@echo "✓ Setup complete! Edit .env then run: make dev"
## Start all services concurrently
dev:
@echo "→ Starting AgentOrch (backend + frontend)..."
@trap 'kill %1 %2' SIGINT; \
(backend/.venv/bin/python -m uvicorn backend.main:app --reload --port 8000) & \
(cd frontend && npm run dev) & \
wait
## Backend only
backend:
backend/.venv/bin/uvicorn backend.main:app --reload --port 8000
## Frontend only
frontend:
cd frontend && npm run dev
## Run tests
test:
backend/.venv/bin/pytest backend/tests/ -v --tb=short --cov=backend --cov-report=term-missing
## Lint
lint:
backend/.venv/bin/ruff check backend
cd frontend && npx tsc --noEmit
## Docker Compose (production-like local stack)
docker:
docker compose up --build
## Clean
clean:
rm -rf backend/.venv backend/__pycache__ backend/**/__pycache__
rm -rf frontend/node_modules frontend/.next
rm -f agentOrch.db agentOrch_checkpoints.db
rm -rf .chroma