Skip to content

Repository files navigation

Barenetes

A minimal Kubernetes implementation written in Rust

Rust License: MIT Issues PRs Welcome GitHub Stars


Barenetes is an open-source, reimplementation of the core Kubernetes control plane in Rust. The goal is to build a working, minimal container orchestrator from scratch.

Status: Early development. Core components are being scaffolded. Not production-ready.


Table of Contents


Overview

Kubernetes is a powerful but complex system. Barenetes strips it down to its essential primitives, reimplementing them in safe, idiomatic Rust. The project is designed to be readable and approachable.

Key design principles:

  • Minimal : only the core orchestration loop, no optional features
  • Transparent : clear separation between components, explicit communication via gRPC
  • Safe : Rust's type system and ownership model enforced throughout

Architecture

Barenetes architecture overview

Components

Barenetes is a Cargo workspace composed of five crates, each mirroring a real Kubernetes component. All inter-component communication uses gRPC / Protocol Buffers.

Crate Equivalent Role
agent kubelet Runs on each node, manages container lifecycle
api kube-apiserver Central hub : accepts requests and coordinates state
barectl kubectl CLI to interact with the API server
scheduler/reconciliator kube-scheduler Assigns workloads to nodes
cni CNI plugin Manages pod networking

Proto definitions live in proto/<component>/v1/.


Getting Started

Prerequisites

  • Rust (edition 2026 / nightly)
  • protoc : Protocol Buffer compiler

Clone

git clone https://github.com/do-2k25-28/Barenetes.git
cd Barenetes

Building

Build the entire workspace:

cargo build

Build a single component:

cargo build -p agent
cargo build -p api
cargo build -p barectl
cargo build -p scheduler
cargo build -p cni

Run a component:

cargo run -p api

Contributing

Contributions are welcome. Please open an issue before submitting a pull request for non-trivial changes so we can discuss the approach first.

  1. Fork the repository
  2. Create a feature branch (git checkout -b feat/my-feature)
  3. Commit your changes
  4. Open a pull request

Please keep PRs focused : one feature or fix per PR.


License

Distributed under the MIT License. See LICENSE for details.


Star History

About

⚓ Open-source minimal container orchestration project, written in Rust.

Topics

Resources

Contributing

Stars

10 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages