Hero - the sovereign everything app
  • Rust 46.3%
  • Shell 39.1%
  • JavaScript 7.3%
  • TypeScript 2.8%
  • Makefile 2.1%
  • Other 2.4%
Find a file
mik-tf da9303d65d
Some checks failed
Build and Test / build (push) Failing after 10s
Build Container / Build and Push Container (push) Failing after 10s
Build Container / Create Release (push) Has been skipped
Build Linux / build-linux (linux-amd64, false, x86_64-unknown-linux-musl) (push) Failing after 14s
Build Linux / build-linux (linux-arm64, true, aarch64-unknown-linux-gnu) (push) Failing after 20s
feat: OSIS migration smoke tests + build patches (#45)
- Add 10 smoke tests for hero_agent OSIS-backed endpoints
  (conversations CRUD, stats, audit, usage, memories)
- Fix cargo-server-patches.toml to avoid duplicate key with
  repos that have their own [patch] sections

Signed-off-by: mik-tf
2026-03-25 19:52:39 -04:00
.forgejo/workflows chore: disable macOS CI workflow — no runner available (#82) 2026-03-23 16:26:41 -04:00
_archive/docs Merge branch 'development_kristof' into development 2026-03-19 11:13:52 +01:00
crates fix: add hero_proc_sdk new required fields (#83) 2026-03-23 17:53:09 -04:00
data feat: complete zinit → hero_proc migration (#65) 2026-03-20 10:31:58 -04:00
deploy/single-vm feat: integration test suite — test locally before deploy (#79) 2026-03-23 10:46:20 -04:00
docker feat: voice pipeline, service fixes, settings UI (#78, #87) 2026-03-24 17:00:20 -04:00
docs feat: complete zinit → hero_proc migration (#65) 2026-03-20 10:31:58 -04:00
node_modules fix: increase E2E navigation timeout for remote testing 2026-03-24 20:20:44 -04:00
profiles feat: replace hero_shrimp with hero_agent (#72) 2026-03-21 12:13:02 -04:00
scripts feat: connection status indicator + UI improvements (#70) 2026-03-20 20:01:36 -04:00
services feat: voice pipeline, service fixes, settings UI (#78, #87) 2026-03-24 17:00:20 -04:00
test-results fix: light mode colors, play/stop toggle, auto-scroll streaming 2026-03-24 22:05:39 -04:00
tests feat: OSIS migration smoke tests + build patches (#45) 2026-03-25 19:52:39 -04:00
.dockerignore refactor: Use zinit client library, remove init module, add Docker support 2026-02-11 12:31:42 +01:00
.env.example Add CODEROOT/BUILDDIR env vars and replace raw git with herolib_os GitTree 2026-02-15 19:14:45 +01:00
.gitignore lhumina_code/home#12 — Fast local build pipeline + container naming fix 2026-03-10 20:59:42 -04:00
bootstrap.sh feat: replace hero_shrimp with hero_agent (#72) 2026-03-21 12:13:02 -04:00
buildenv.sh fix: rename hero_fossil to hero_foundry in build paths and config 2026-03-08 18:38:34 -04:00
Cargo.toml bump herolib_os version from 0.3.14 to 0.4 2026-03-20 18:32:18 +01:00
Dockerfile.pack feat: voice pipeline, service fixes, settings UI (#78, #87) 2026-03-24 17:00:20 -04:00
LICENSE Initial commit 2026-01-09 21:39:18 +00:00
Makefile feat: unit tests + test-all target + adversarial tests (#90) 2026-03-25 16:33:34 -04:00
package-lock.json feat: Playwright E2E tests for voice UI (#78, #87) 2026-03-24 20:14:43 -04:00
package.json feat: Playwright E2E tests for voice UI (#78, #87) 2026-03-24 20:14:43 -04:00
playwright.config.ts feat: Playwright E2E tests for voice UI (#78, #87) 2026-03-24 20:14:43 -04:00
README.md feat: add dist-clean-wasm target, fix WASM patches, update docs (#69) 2026-03-20 16:17:57 -04:00

Hero Services

Service orchestrator for the Hero OS ecosystem. Manages the lifecycle of all Hero services — building, installing, starting, stopping, and monitoring via JSON-RPC over Unix sockets.

For Users (Quickstart)

Pull the image and run — no build tools required.

docker pull forge.ourworld.tf/lhumina_code/hero_zero:hero
docker run -d --name hero -p 8080:6666 forge.ourworld.tf/lhumina_code/hero_zero:hero

Open http://localhost:8080 in your browser:

  1. Register — create your account through the UI
  2. Settings — add API keys (OpenRouter, Groq, etc.) from the Settings page
  3. Done — no terminal needed after the initial pull

For Developers

1. Bootstrap

Clone the full workspace (hero_services + all 18 service repos + hero_proc):

mkdir -p ~/hero/src/lhumina_code && cd ~/hero/src/lhumina_code
curl -sSfL https://forge.ourworld.tf/lhumina_code/hero_services/raw/branch/development/bootstrap.sh | bash

Re-running is safe — existing repos are pulled, not re-cloned.

2. Build & run locally

All builds compile inside Docker — no local Rust toolchain needed. Three build targets for different situations:

cd hero_services
source ~/hero/cfg/env/env.sh

# Full build (cached — fast when cache is warm)
make dist

# Server-only build (fastest — skip WASM shell + shrimp)
make dist-quick

# Clean WASM rebuild (nuke WASM cache — use when dock/island changes aren't picked up)
make dist-clean-wasm
Target What rebuilds When to use Time
make dist Everything (cached) Default ~10 min
make dist-quick Server binaries only Backend changes (routes, RPC, templates, JS) ~5 min
make dist-clean-wasm Everything + fresh WASM Dock layout, island metadata, registry.rs ~25 min

Then pack and run:

TAG=0.1.0-dev make pack     # bundle dist/ into Docker image
docker stop herolocal; docker rm herolocal
docker run -d --name herolocal -p 8080:6666 \
  -e OPENROUTER_API_KEY="$OPENROUTER_API_KEY" \
  -e GROQ_API_KEY="$GROQ_API_KEY" \
  -e HERO_SECRET="dev-secret-change-in-production" \
  -e FORGEJO_TOKEN="$FORGEJO_TOKEN" \
  forge.ourworld.tf/lhumina_code/hero_zero:0.1.0-dev
# Wait ~120s, then open http://localhost:8080 — login: admin / admin123
make smoke              # run smoke tests against local container
make logs               # follow container logs
make stop               # stop and remove container

3. Ship to VM (no registry needed)

# Option A: via registry
make push                                          # push to forge.ourworld.tf
cd deploy/single-vm && make update ENV=herodev     # pull + restart on VM

# Option B: direct transfer (when registry is slow/down)
docker save forge.ourworld.tf/lhumina_code/hero_zero:herodev | gzip > /tmp/hero.tar.gz
scp /tmp/hero.tar.gz root@<vm>:/tmp/
ssh root@<vm> "docker load < /tmp/hero.tar.gz && /usr/local/bin/heroos-run.sh"

Environment Variables — 3 Ways

Method When to use
UI Settings Easiest — set API keys from the browser, no terminal needed
Source env files source ~/hero/cfg/env/* before running locally
CLI params Pass directly as arguments to binaries

If nothing is set, the UI prompts you to configure on first use.

Versioning & Releases

Follows semver 2.0. Version is defined in two places that must match:

  • Cargo.tomlversion = "0.1.0"
  • buildenv.shexport VERSION=0.1.0

Image tags

Tag Purpose
hero_zero:0.1.0-dev Development builds (deployed to herodev)
hero_zero:0.1.0-rc1 Release candidate, ready for testing
hero_zero:0.1.0 Stable release
hero_zero:herodev Alias — always points to latest dev build

Override the tag when packing: make pack TAG=0.1.0-dev

Git tags & CI

Git tags trigger CI builds and package publishing:

git tag v0.1.0-dev
git push origin v0.1.0-dev    # triggers build-linux.yaml → package registry

Tag format: v{MAJOR}.{MINOR}.{PATCH}[-PRERELEASE]

Release workflow

  1. Verify version matches in Cargo.toml and buildenv.sh
  2. Tag and push: git tag v0.1.0-dev && git push origin v0.1.0-dev
  3. CI publishes binaries to forge.ourworld.tf package registry
  4. Create release page via forge API or UI with changelog

Crates

Crate Type Purpose
hero_services_sdk library Types, RPC client, shared protocol
hero_services_server binary Daemon, JSON-RPC over Unix socket
hero_services binary CLI client using SDK
hero_services_ui binary Axum admin panel using SDK
hero_services_examples examples Example programs demonstrating SDK usage

CLI

hero_services health                    # Check server health
hero_services list                      # List all services
hero_services start|stop|restart <name> # Control a service
hero_services logs [name] [-n LINES]    # View logs
hero_services config [name]             # Show configuration
hero_services install <name>            # Install a service
hero_services install-all               # Install all services
hero_services build-status              # Show build progress

Runtime Directories

~/hero/
├── bin/                          # Service binaries
├── src/                          # Source code (for build method)
├── var/
│   ├── sockets/                  # Unix domain sockets
│   └── hero_zero/
│       └── installed/            # Install tracking
└── cfg/
    ├── env/                      # Environment variable files
    └── hero_proc/                # hero_proc service configs

Requirements (developers only)

  • Rust 1.93+ (edition 2024)
  • Git, Make, hero_proc
  • Docker (required — all builds run in containers)

Add ~/hero/bin to your $PATH:

export PATH="$HOME/hero/bin:$PATH"

License

Apache-2.0