Skip to content

SamuelMarks/cdd-ctl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

102 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cdd-ctl

The central daemon manager, API gateway, and backend infrastructure for the cdd-* SDK toolchain.

CI License Test Coverage Doc Coverage

cdd-ctl is a high-performance Rust backend that orchestrates a multi-language JSON-RPC ecosystem. It provides an integrated daemon manager to supervise child processes alongside a comprehensive, OpenAPI-driven web backend. Built with Role-Based Access Control (RBAC), cdd-ctl securely manages organizations, SDK repositories, and software releases.

Features

Feature Description
Daemon Manager A built-in supervisor that manages the lifecycle, logging, and auto-restart backoff for up to 13 distinct cdd-* JSON-RPC language servers.
REST API Gateway A high-performance RESTful API built on the actix-web framework.
Database & ORM Robust PostgreSQL data modeling using diesel to manage organizations, users, repositories, and releases.
GitHub Integration Seamlessly supports GitHub OAuth, webhooks, and automated secret management using Libsodium.
Authentication Secure JWT-based Bearer authentication, including an OAuth2 password grant flow with Argon2 hashing.
Access Control (RBAC) Organization ownership models that securely isolate management of SDKs and synchronization processes.
OpenAPI Integration Fully self-documenting. Exposes a live Swagger UI at /swagger-ui/ out of the box using utoipa.
Quality Assurance Maintained with strict 100% test and rustdoc coverage requirements (cargo tarpaulin), enforced in CI.

Supported Ecosystems

cdd-ctl daemonizes and interfaces with the following language SDKs:

Repository Language Client; Client CLI; Server Extra features Standards CI Status Browser/WASI WASM Notes
cdd-c C (C89) Client; Client CLI; Server FFI Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 0.80MB - Executes via pure WASI
cdd-cpp C++ Client; Client CLI; Server Upgrades Swagger & Google Discovery to OpenAPI 3.2.0 Google Discovery; Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 4.40MB - Executes via pure WASI
cdd-csharp C# Client; Client CLI; Server CLR Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 5.44MB - Executes via pure WASI (Wasi.Sdk)
cdd-go Go Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 14.14MB - Executes via pure WASI
cdd-java Java Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 21.39MB - Executes via pure WASI (GraalVM native-image)
cdd-kotlin Kotlin (ktor for Multiplatform) Client; Client CLI; Server Auto-Admin UI Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 0.45MB - Executes via pure WASI
cdd-php PHP Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 24.79MB - Executes via pure WASI
cdd-python-all Python Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 48.11MB - Executes via WASI (py2wasm)
cdd-ruby Ruby Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 51.21MB - Executes via WASI (rbwasm)
cdd-rust Rust Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 4.72MB - Executes via pure WASI
cdd-sh Shell (/bin/sh) Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 10.48MB - Executes via pure WASI
cdd-swift Swift Client; Client CLI; Server Swagger 2.0 & OpenAPI 3.2.0 CI ✅ Supported 94.83MB - Executes via pure WASI
cdd-ts TypeScript Client; Client CLI; Server Auto-Admin UI; Angular; React; Vue; fetch; Axios; Node.js Swagger 2.0 & OpenAPI 3.2.0 Tests and coverage ✅ Supported 14.68MB - Executes via WASI (Node.js polyfilled)

Note: See cdd_docs_prompt.md and TO_DOCS_JSON.md in this repository for the system prompts used to unify documentation and CLI interfaces across the entire cdd-* ecosystem.

Browser-Native Execution

In addition to CLI and server modes, the project includes cdd-ctl-wasm-sdk, a pure-JavaScript WASI-compatible execution environment. This allows you to evaluate your OpenAPI generation schemas directly in the browser. You can run any of our 12 fully supported cdd-* WASM binaries (C, C++, C#, Go, Java, Kotlin, PHP, Python, Ruby, Rust, Swift, TypeScript) entirely client-side, with no backend communication required.

Heavy-VM runtimes gracefully degrade to using JSON-RPC over HTTP rather than running locally in the browser.

Documentation

For detailed guides on configuring cdd-ctl and utilizing the cdd-* architecture, please refer to our comprehensive documentation:

Quick Start

Starting the Server

You can launch the API gateway and daemon manager locally using Cargo:

# Native dependencies mode (REST interface)
cargo run --bin cdd-ctl --release -- --bind 0.0.0.0:8080 --config ./config.json

# WASM mode (runs compiled WASM binaries via wasmtime, REST interface)
cargo run --bin cdd-ctl-wasm --release -- --bind 0.0.0.0:8081 --config ./config.json

# JSON-RPC Native dependencies mode (JSON-RPC over HTTP)
cargo run --bin cdd-rpc --release -- --bind 0.0.0.0:8082 --config ./config.json

# JSON-RPC WASM mode (runs compiled WASM binaries via wasmtime, JSON-RPC over HTTP)
cargo run --bin cdd-rpc-wasm --release -- --bind 0.0.0.0:8083 --config ./config.json

Accessing the API

Once the server is running, the interactive OpenAPI documentation and sandbox will be available at: http://localhost:8080/swagger-ui/


License

This project is dual-licensed under either of the following, at your option:

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual-licensed as above, without any additional terms or conditions.

About

API gateway and JSON-RPC process manager for cdd-*

Resources

License

Apache-2.0, MIT licenses found

Licenses found

Apache-2.0
LICENSE-APACHE
MIT
LICENSE-MIT

Stars

Watchers

Forks

Packages

 
 
 

Contributors