1. meshctl CLI and Orchestration#

meshctl is the declarative fleet management and orchestration CLI for FleetMesh. Implemented in Rust, it provides operators with a standalone, minimal-dependency control utility to inspect, reconcile, monitor, and deploy FleetMesh nodes and peering topologies.

FleetMesh Logo

1.1. Overview and Capabilities#

Whereas meshnode operates as the persistent runtime daemon responsible for peer connections, cryptographic stores, and message routing, meshctl serves as the administrative control plane. It processes Kubernetes-style declarative manifests (apiVersion: fleetmesh.org/v1alpha1) and communicates directly with local or remote node instances:

  • Declarative Manifests (meshctl apply, diff, export), experimental: apply atomically reconciles MeshNode and Peering manifests against a node and publishes Network manifests to their relays; diff compares manifest fields against the node’s config.json configuration; export renders MeshNode and BrandManifest manifests into Docker Compose, Kubernetes, systemd, Podman Quadlet, dotenv, or node-consumable JSON deployment artifacts. See Manifests: apply and diff and Manifests: export.

  • Fleet Observation and Monitoring (meshctl watch): Provides consolidated status reporting across an entire fleet over SSH, verifying protocol digest agreement, relay connectivity, compartment health, and CI pipeline status.

  • Independent Rust Conformance Engine (meshctl conform): Provides a clean-room implementation of FleetMesh protocol mechanisms built solely from the normative specifications and test vectors for independent conformance verification.

  • Linked Data Projections (meshctl linked): Extracts and displays schema.org JSON-LD descriptors for node services, standing reports, and Blossom blobs.

1.2. Architecture and Design#

meshctl follows a minimalist, statically compiled design focused on operational reliability:

Aspect

Architecture Decision

Language and Toolchain

Rust 2021 (MSRV 1.84), compiled as a statically linked standalone binary.

Transport and Control

Local Unix domain socket IPC using the meshnode-control/1 protocol, exposing no network administrative ports.

Network Dependencies

Uses tungstenite and rustls with webpki-roots for relay queries without an asynchronous runtime dependency, minimizing binary footprint.

Security Sandbox

Rootless execution by default. Remote administration operates over standard SSH without requiring auxiliary remote agent daemons.

1.3. Installation#

Install from crates.io:

cargo install meshctl --version 0.5.0-alpha.1

Or run the official multi-arch distroless container image (linux/amd64 and linux/arm64, statically linked musl binary with embedded cargo-auditable dependency metadata on cgr.dev/chainguard/static, running as non-root UID 65532) without installing a Rust toolchain:

podman run --rm --read-only docker.io/fleetmesh/meshctl:0.5.0-alpha.1 --version

# Mount $PWD at /work for local keys or manifests, or a node state directory:
podman run --rm --read-only \
  -v "$PWD:/work" \
  docker.io/fleetmesh/meshctl:0.5.0-alpha.1 fleet list --key-file operator.key --relay wss://relay.fleetmesh.org

To build and install from a workspace checkout:

cd mesh-rs
cargo install --path crates/meshctl

To verify a local checkout directly without installing:

cargo run -- version

1.4. Quick Start#

# Check status of local node daemon
meshctl status --dir /var/lib/fleetmesh

# Inspect JSON-LD schema.org service descriptor
meshctl linked service --dir /var/lib/fleetmesh | jq .

1.5. Subsystems and Documentation#

Document

Description

meshctl CLI Reference

Reference for all meshctl commands, flags, subcommands, and exit codes.

Manifests: apply and diff

Experimental. Field-by-field manifest mapping and reconciliation semantics for apply and diff.

Manifests: export

Experimental. Deployment artifact generation for Compose, Kubernetes, systemd, Quadlet, JSON, and dotenv targets via export.

Fleet Monitoring and Supervision (meshctl watch)

Fleet health monitoring over SSH, systemd timer integration, and protocol digest drift detection.

Independent Rust Conformance Engine

Clean-room Rust conformance engine, conformance wire protocol specification, and test vector coverage.