Typed, repeatable operations for Linux hosts.
The controller puts each job on a queue. It does not call the host.
OSAPI makes a Linux host operate like an appliance. One binary and one configuration file give you a REST API, a CLI, a Go SDK and an embedded dashboard. They manage a fleet of hosts, not only one host. They control these parts of each host:
- hostname, DNS, disk, memory and load
- packages, services, users, sysctl and cron
- certificates, containers, files and command execution
CLI / SDK / UI -> Controller (REST API) -> NATS JetStream -> Agents
The controller never changes the operating system. It writes a job and waits. An agent on the managed host receives the job. Then a provider on that host does the work. Delivery is at-least-once, so each provider must be safe to run two times. The remainder of the design follows from this constraint.
A job can go to:
- one host, by its name
- all hosts in the fleet, as a broadcast
- any one free agent, for load balance
- the hosts that have a given label
| Project | Release | Stars | Description |
|---|---|---|---|
| osapi | The controller, the agent, the CLI, the SDK and the embedded dashboard | ||
| osapi-orchestrator | Runs multi-step operations across OSAPI-managed hosts | ||
| gohai | Collects system facts, like Chef Ohai | ||
| nats-client | Connects to NATS and JetStream | ||
| nats-server | Runs a NATS server inside a Go process | ||
| osapi-justfiles | The just recipes that every repository here imports |
||
| specs | The design docs, written before the code | ||
| osapi-lab | Tart VMs on a Mac that run an osapi branch across real distributions |
Start with osapi. Each other repository is a library that osapi imports, or a tool that reads osapi.
Design comes first. A change starts as a page in specs. Then we build the change. Then we correct the page where the build showed that the design was wrong. It is one page in all three steps. We do not convert it from one form into another. Thus the design and the documentation always agree.
# run the controller, the agent and NATS together
osapi start
# ask one host its hostname
osapi client node hostname --target web-01
# ask every host for its users
osapi client node user list --target _all
# open the dashboard
open http://localhost:8080Documentation | API reference | Contributing | Security | Code of conduct | AI policy