8dd350286e
- Add Docker Compose and Dockerfile support for tool definitions - Implement readiness probes with configurable command, timeout, interval - Create ConfigFolder model for reusable file collections with project overrides - Add rich tool config fields: port_override, start_command, working_directory, env vars, volumes - Build unified Tool Workshop UI at /tool-workshop replacing /tool-configs and /tool-types - Update instance creation to support dockerfile builds, config folder mounting, readiness probes - Add 3 database migrations for tool_types, tool_configs, and new config_folders table - Create docker_build.py and readiness_probe.py services - Add config_folders API with CRUD and project override endpoints Quality gates: frontend build passes, Python syntax valid, all phases complete Addresses tool-workshop OpenSpec change
58 lines
3.4 KiB
Markdown
58 lines
3.4 KiB
Markdown
## Why
|
|
|
|
The current tool system is too rigid. Tool types are hardcoded with compose templates, configs are simple key-value pairs, and the UI is a basic flat list. Users need a true "tool workshop" where they can:
|
|
|
|
1. **Define new tools** with either Docker Compose or Dockerfile
|
|
2. **Configure rich tool settings** including ports, commands, working directories, and volume mounts
|
|
3. **Create reusable config file collections** (e.g., dotfiles, IDE settings) that mount into containers
|
|
4. **Wait for tools to be ready** with configurable health/readiness probes before considering the build complete
|
|
|
|
This unlocks the platform from built-in tools to a true marketplace of user-defined and user-configured tools.
|
|
|
|
## What Changes
|
|
|
|
- **Enhance ToolType model**: Add `dockerfile_template`, `readiness_probe` (command + timeout), `build_context` field
|
|
- **Enhance ToolConfig model**: Add `port_override`, `start_command`, `working_directory`, `environment_variables`, `volumes`
|
|
- **Create ConfigFolder model**: Named collections of files mountable as volumes, with per-project overrides
|
|
- **Add readiness probe system**: Instance creation waits for probe command with configurable timeout
|
|
- **Unified Tool Workshop UI**: Single page replacing `/tool-configs` and `/tool-types` with:
|
|
- Tool Type builder (compose or dockerfile)
|
|
- Tool Config editor (split-pane with all new fields)
|
|
- Config Folder manager (file collections with mount paths)
|
|
- Live validation and preview
|
|
- **Update instance creation flow**: Support dockerfile builds, mount config folders, apply readiness probes
|
|
- **Database migrations**: New columns on `tool_types`, `tool_configs`; new `config_folders` table
|
|
|
|
## Capabilities
|
|
|
|
### New Capabilities
|
|
- `tool-workshop`: Unified tool definition, configuration, and deployment interface
|
|
- `config-folders`: Reusable per-user file collections mountable into containers with per-project overrides
|
|
- `readiness-probes`: Build-time health checks that wait for tools to be ready before marking instances as running
|
|
|
|
### Modified Capabilities
|
|
- `tool-types`: Enhanced with dockerfile support, readiness probes, build context
|
|
- `tool-config-management`: Extended with port overrides, volumes, environment variables, working directory
|
|
- `tool-instances`: Instance creation supports dockerfile builds, config folder mounts, probe waiting
|
|
|
|
## Impact
|
|
|
|
- **Backend**:
|
|
- Models: `ToolType`, `ToolConfig`, new `ConfigFolder`
|
|
- API: New endpoints for config folders, updated tool type/config endpoints
|
|
- Services: Docker build service (for dockerfiles), readiness probe service
|
|
- Instance creation: Dockerfile build path, volume mounting, probe execution
|
|
- **Frontend**:
|
|
- New `ToolWorkshopPage` component (replaces `/tool-configs` and `/tool-types`)
|
|
- New components: Dockerfile editor, readiness probe config, config folder manager, volume mount editor
|
|
- Updated routing and navigation
|
|
- **Database**:
|
|
- `tool_types`: Add `dockerfile_template`, `readiness_probe`, `build_context`
|
|
- `tool_configs`: Add `port_override`, `start_command`, `working_directory`, `environment_variables`, `volumes`
|
|
- New `config_folders` table
|
|
- **User Experience**: Users can now define entirely new tools, configure them richly, and reuse config collections across projects
|
|
|
|
## Supersedes
|
|
|
|
This change supersedes `tool-config-ui-rework` which scoped only to the UI rework and basic new fields. This is a comprehensive expansion of the tool system.
|