Thank you for your interest in contributing to CubeOS! This guide covers everything you need to get started.
- Go 1.24+ (CGO disabled — all builds use
CGO_ENABLED=0) - Node.js 20+ (for the dashboard)
- Docker with Swarm mode enabled (
docker swarm init) - shellcheck (for shell script linting)
| Repo | Language | What lives here |
|---|---|---|
api |
Go | Backend REST API — handlers, managers, orchestrator, FlowEngine |
hal |
Go | Hardware Abstraction Layer — GPIO, I2C, sensors, network, power |
dashboard |
Vue 3 | Web management UI — Pinia stores, Tailwind styling |
coreapps |
Docker Compose | System service configs (Pi-hole, NPM, registry, etc.) |
releases |
Packer + Shell | Image builds, installer scripts, release automation |
docs |
Markdown | Architecture docs, user guides, API contracts |
demo |
CI config | Builds and deploys demo.cubeos.app |
- Run
gofmtbefore committing — CI enforces this - All exported HTTP handlers must include complete Swagger annotations:
@Summary,@Description,@Tags,@Param,@Success,@Failure,@Router - Handle all errors — never use
_to discard an error return - No hardcoded IPs, ports, or host URLs — use
os.Getenv()with defaults - No CGO — use
modernc.org/sqlite, notmattn/go-sqlite3 - Use
context.Contextfor cancellation and timeouts - Prefer table-driven tests
- Composition API with
<script setup>— never Options API - Pinia for state management
- Tailwind CSS utility classes only — no custom CSS files
- Monochrome SVG icons only — no emojis anywhere in the UI
- Must be fully responsive (PC and smartphone)
shellcheckmust pass with no warnings- Use
set -euo pipefailat the top of every script - Quote all variables
- Fork the repository
- Create a feature branch:
feat/description,fix/description, ordocs/description - Make your changes and ensure tests pass
- Submit a PR against
main - Wait for CI to pass and a maintainer review
Keep PRs focused — one feature or fix per PR.
| Repo | Command |
|---|---|
| api | cd api && go test -v ./... |
| hal | cd hal && go test -v ./... |
| dashboard | cd dashboard && npm run test |
| releases | bash -n scripts/*.sh (syntax check) + shellcheck scripts/*.sh |
Run the full test suite before submitting a PR.
For architecture decisions, data flows, and design rationale, see the docs repo:
02_ARCHITECTURE.md— component interaction and data flows03_DATABASE_SCHEMA.md— full SQL schema04_BOOT_SEQUENCE.md— startup order and recovery07_API_CONTRACTS.md— OpenAPI endpoint specifications
CubeOS is licensed under Apache 2.0. By contributing, you agree that your contributions will be licensed under the same terms.