Skip to content

Latest commit

 

History

History
127 lines (91 loc) · 2.13 KB

File metadata and controls

127 lines (91 loc) · 2.13 KB

lerees

lerees is a local-first developer dashboard for service health checks, realtime logs, masked environment inspection, and safe quick actions.

Non-goals

  • Production monitoring
  • Kubernetes / swarm orchestration
  • CI/CD pipeline deployment
  • Remote secret vault integrations

Architecture

  • Backend: Rust daemon (axum) for REST + WebSocket + CLI
  • Frontend: Next.js App Router dashboard
  • Templates: config starter packs for common stacks

Quickstart

1) Backend

cd backend
cargo run -- serve --config ../lerees.config.yml

Backend default: http://127.0.0.1:4000

2) Frontend

cd frontend
pnpm install
pnpm dev

Set API base in frontend/.env.local:

NEXT_PUBLIC_API_BASE=http://127.0.0.1:4000

Frontend default: http://127.0.0.1:3000

CLI

cd backend
cargo run -- templates list
cargo run -- init node-prisma --project-name my-app
cargo run -- serve --config ../lerees.config.yml

Backend API (MVP)

  • GET /api/ping
  • GET /api/config
  • GET /api/services
  • GET /api/services/status
  • POST /api/services/status/refresh
  • GET /api/logs/sources
  • GET /api/env
  • GET /api/actions
  • POST /api/actions/{id}/run
  • GET /api/db/status
  • GET /ws/logs

All HTTP responses use a standard envelope:

{
  "ok": true,
  "timestamp": "ISO-8601",
  "data": {},
  "error": null,
  "meta": {}
}

Security Model

  • Command execution uses parsed binary + args with shell=false
  • Binary must be in security.commandAllowlist
  • Command output is capped and redacted (best effort)
  • Environment values are masked based on regex patterns
  • Dangerous actions can require explicit confirmed=true

Templates

Current bundled templates:

  • node-prisma
  • go-compose

Each template includes:

  • meta.json
  • lerees.config.yml
  • README.md

Development

Backend:

cd backend
cargo fmt
cargo test
cargo run -- --help

Frontend:

cd frontend
pnpm build

Contributing

  1. Keep changes focused and reviewable.
  2. Add tests for critical logic (especially security).
  3. Never expose secrets in logs, APIs, or test snapshots.

License

MIT