Codai for Openclaw

Codai is a centralized orchestration skill for managing local development environments, routing complex commands to specialized database and proxy managers.

pereirajair
v1.0.1
May 10, 2026
0
711
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install codai

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install codai using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Codai?

Codai serves as the primary brain for the codai-dev local development ecosystem. Instead of requiring developers to memorize specific script locations for various infrastructure components, this Openclaw Skills entry acts as a router that intelligently directs requests to the appropriate sub-plugins including mysql-manager, postgres-manager, redis-manager, and worktree-manager.

By unifying environment management, Codai allows for seamless infrastructure control using natural language or CLI triggers. It handles the heavy lifting of environment synchronization, ensuring that networks, proxies, and database instances are initialized in the correct sequence to prevent connectivity errors and data loss during local development.

Codai Use Cases

  • Automating the startup of complex local stacks including Nginx proxies and multiple database engines.
  • Creating isolated git worktrees with automatically cloned and migrated databases for feature testing.
  • Performing safe database dumps from a main source of truth to specific feature branches.
  • Auditing the status of all running local containers and proxy routes through a single command.
  • Rapidly cleaning up development environments by removing worktrees, containers, and env files in one step.

How Codai Works

  1. The user provides a command related to the environment (e.g., 'start environment' or 'create worktree').
  2. Codai identifies the target plugin based on the internal Plugin Map (mysql, postgres, proxy, or worktree).
  3. It verifies the dependency sequence, ensuring the Nginx proxy and network are active before databases or app instances.
  4. The skill executes the underlying shell scripts located in the codai-dev-base directory.
  5. Upon completion, it validates the status of the service and reports accessible URLs to the user.

Codai Setup

To integrate this into your Openclaw Skills workflow, ensure you have the codai-dev-base structure and the required binaries installed.

# Ensure dependencies are available
# Requires: docker, git

# Navigate to your local base directory
cd codai-dev-base

# The skill expects the following directory structure:
# ./mysql/run.sh
# ./nginx-proxy/run.sh
# ./run.sh (for worktree management)

Codai Data Schema & Taxonomy

Codai manages environment state through shared variables and specific directory structures. Below is the metadata and variable taxonomy:

Variable Default Value Role
MYSQL_MAIN_DB codai_main The source of truth for database clones
CODAI_NETWORK nginx-proxy_net Shared Docker network for all services
PROXY_CONTAINER codai_nginx_proxy Central entry point for frontend/backend routing
PROJECT_PREFIX codai-dev Namespace for container and resource isolation

Worktrees are generated in .worktrees/<name> with corresponding .env.worktree-<name> files to maintain isolation.

Codai Advanced Features

  • Intelligent Startup Sequencing: Automatically enforces the Proxy > Database > App startup order to ensure network availability.
  • Main DB Protection: Built-in safeguards prevent the accidental dropping of the codai_main database.
  • Automated Proxy Connection: Dynamically connects new worktree instances to the Nginx proxy for instant access via .localhost domains.
  • Comprehensive Environment Status: Aggregates health checks from all sub-plugins into a single unified report.
  • Irreversible Action Confirmation: Mandatory user validation before performing destructive operations like worktree removal.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*