shai-mega
Comprehensive development environment with multiple language runtimes, tools, and pre-installed AI CLIs.
Overview
shai-mega is a kitchen-sink image designed to get you started quickly with Shai. It includes everything you need for polyglot development with AI agents.
Registry: ghcr.io/colony-2/shai-mega:latest
Base: ghcr.io/colony-2/shai-base:latest (Debian bookworm-slim)
Size: ~2 GB
Default: This is Shai’s default image when no config is specified
What’s Included
Languages & Runtimes
- Go - Latest stable (1.21+)
- Rust - Stable toolchain with cargo
- Node.js - Latest LTS with npm, yarn, pnpm
- Python - Python 3.11+ with pip
- Java - OpenJDK (default-jdk)
- C/C++ - GCC and Clang compilers
Package Managers
- npm - Node.js package manager
- yarn - Alternative Node.js package manager
- pnpm - Fast, disk-efficient Node.js package manager
- pip - Python package installer
- cargo - Rust package manager
AI CLI Tools
- Claude Code - Anthropic’s official CLI
- Codex - OpenAI’s coding agent (if available)
- Gemini CLI - Google’s AI CLI
- Moonrepo - Repository management tool
Browser Automation
- Playwright - Browser testing framework
- Chromium - Headless browser
Development Tools
- git - Version control
- jq - JSON processor
- curl - HTTP client
- wget - File downloader
- bash-completion - Shell completions
- vim - Text editor
- nano - Simple text editor
- htop - Process viewer
- tree - Directory tree viewer
- rsync - File synchronization
- ssh - Secure shell client
Build Tools
- build-essential - Essential build tools (make, gcc, etc.)
- pkg-config - Library configuration helper
- cmake - Cross-platform build system
System Tools
All tools from shai-base plus:
- zsh - Advanced shell
- tmux - Terminal multiplexer
- supervisor - Process manager
- iptables - Firewall
- tinyproxy - HTTP proxy
- dnsmasq - DNS server
Use Cases
1. Quick Start
Get started with Shai immediately without building custom images:
1npm install -g @colony2/shai
2shai -rw src -- claude-code2. Polyglot Development
Work on projects using multiple languages:
1# Monorepo with Go backend + Node.js frontend
2shai -rw services/api -rw packages/web-app3. AI Agent Development
Pre-installed AI tools mean agents can run immediately:
1# Claude Code is already installed
2shai -rw . -- claude-code
3
4# Or Gemini CLI
5shai -rw . -- gemini-cli4. Full-Stack Development
Everything you need for modern web development:
1# React frontend + Node.js backend + Python ML
2shai -rw frontend -rw backend -rw mlConfiguration Example
1# .shai/config.yaml
2type: shai-sandbox
3version: 1
4
5# shai-mega is the default, but can be explicit
6image: ghcr.io/colony-2/shai-mega
7
8resources:
9 base-allowlist:
10 http:
11 - github.com
12 - npmjs.org
13 - pypi.org
14 - crates.io
15
16apply:
17 - path: ./
18 resources: [base-allowlist]Pre-Installed Tools Locations
All language toolchains are installed system-wide:
1# Go
2/usr/local/go/bin/go
3
4# Rust
5/usr/local/cargo/bin/cargo
6/usr/local/cargo/bin/rustc
7
8# Node.js
9/usr/bin/node
10/usr/bin/npm
11
12# Python
13/usr/bin/python3
14/usr/bin/pip3
15
16# AI Tools
17/usr/local/bin/claude-code
18/usr/local/bin/gemini-cliPATH is pre-configured for all users.
Version Information
Check installed versions:
1shai -- bash -c "
2 echo Go: \$(go version)
3 echo Rust: \$(rustc --version)
4 echo Node: \$(node --version)
5 echo Python: \$(python3 --version)
6"Performance Considerations
Startup Time
- Cold start (first pull): 2-5 minutes (large download)
- Warm start (cached): ~2 seconds
Pre-warm the image for faster first run:
1docker pull ghcr.io/colony-2/shai-mega:latestResource Usage
- Disk: ~2 GB
- Memory: 100-200 MB (sandboxing) + your application
- CPU: Minimal overhead
Optimization Tips
Use cache mounts to avoid re-downloading packages:
1resources: 2 caches: 3 mounts: 4 - source: ${{ env.HOME }}/.npm 5 target: /home/shai/.npm 6 mode: rw 7 - source: ${{ env.HOME }}/.cargo 8 target: /home/shai/.cargo 9 mode: rwPre-install dependencies in your project’s setup scripts
Use shai-base for CI/CD where you don’t need all tools
When to Use shai-mega
✅ Use shai-mega if:
- You’re just getting started with Shai
- You work on multiple projects with different languages
- You want AI tools pre-installed
- You don’t want to manage custom images
- Disk space isn’t a concern
- You value convenience over image size
❌ Don’t use shai-mega if:
- You need a minimal image (use shai-base)
- You’re running in resource-constrained CI/CD
- You have specific version requirements (build custom)
- You need specialized tools not included
- You need GPU support (build custom from shai-base)
- Image size is critical
Updating
Pull Latest Version
1docker pull ghcr.io/colony-2/shai-mega:latestCheck for Updates
1# See current image ID
2docker images ghcr.io/colony-2/shai-mega
3
4# Pull and compare
5docker pull ghcr.io/colony-2/shai-mega:latestVersioning
Available tags:
latest- Latest stable release (recommended)v1.0.0- Specific version (for reproducibility)main- Latest build from main branch (unstable)
Recommendation: Use latest for development, pin versions in CI/CD:
1# Development
2image: ghcr.io/colony-2/shai-mega
3
4# CI/CD
5image: ghcr.io/colony-2/shai-mega:v1.0.0Customizing shai-mega
You can extend shai-mega if you need additional tools:
1FROM ghcr.io/colony-2/shai-mega:latest
2
3# Add additional tools
4RUN apt-get update && apt-get install -y \
5 postgresql-client \
6 redis-tools \
7 && rm -rf /var/lib/apt/lists/*
8
9# Install additional npm packages globally
10RUN npm install -g \
11 typescript \
12 @nestjs/cli
13
14WORKDIR /srcTroubleshooting
Image Pull Timeout
Problem: Pulling shai-mega times out
Solution: The image is large (~2 GB). Ensure stable network:
1# Increase Docker pull timeout
2DOCKER_CLI_TIMEOUT=600 docker pull ghcr.io/colony-2/shai-mega:latestTool Version Conflicts
Problem: Need a specific version not in shai-mega
Solution: Build a custom image based on shai-base
Missing Tool
Problem: Tool you need isn’t included
Solution: Either extend shai-mega or build from shai-base:
1FROM ghcr.io/colony-2/shai-mega:latest
2RUN apt-get update && apt-get install -y your-toolComparison with shai-base
| Feature | shai-base | shai-mega |
|---|---|---|
| Size | ~200 MB | ~2 GB |
| Languages | None | 6+ languages |
| AI Tools | None | 3+ tools |
| Startup | Fast | Moderate |
| Use Case | Custom images, CI | Quick start, development |
| Flexibility | Maximum | High (but opinionated) |
Next Steps
- Compare with shai-base for minimal images
- Learn to build Custom Images for specialized needs
- See Examples for real-world usage