AgentSkillsCN

agentic-ecosystem-docker

当使用 Docker Compose 将多服务代理生态系统(包括 UI + 智能体管理服务器,以及可选的启动器/数据摄取器)容器化时,应使用此技能——同时兼顾仅限本地访问的安全性、正确的容器内网络配置、统一的日志卷挂载,以及可用的 Codex/Claude CLI。

SKILL.md
--- frontmatter
name: agentic-ecosystem-docker
description: This skill should be used when containerizing a multi-service agentic ecosystem (UI + Agent Management Server, optionally launchers/ingestors) with Docker Compose while preserving localhost-only security, correct in-container networking, centralized log volume mounts, and working Codex/Claude CLIs.

Agentic Ecosystem Docker

[Created by Codex: 019b78e6-c6cb-7f72-ab5a-c16c536b8e70]

Purpose

Provide a repeatable workflow and checklists for Dockerizing the agentic ecosystem so docker compose up --build runs the UI and AMS with working /api/agent-sdk/*, Live Logs (SSE), and agent start/stop.

When To Use

  • Need to run Agent HQ (or similar Vite UI) + AMS together via Docker Compose
  • Need localhost-only exposure (bind 127.0.0.1:PORT:PORT)
  • Seeing 403 forbidden from /api/agent-sdk/* or SSE endpoints in Docker (loopback checks)
  • Need to mount centralized logs and provider CLIs into containers

Non-Negotiable Contract

  • Publish the UI port only on loopback (example: 127.0.0.1:8037:8037)
  • Do not publish AMS port (use expose, not ports)
  • Bind Vite to 0.0.0.0 inside container
  • Use Docker hostname for AMS from the UI (http://ams:8041)
  • Run smoke tests after each phase before continuing

Workflow

  1. Load references/agentic_ecosystem_docker_playbook.md and follow phases in order.
  2. If a Linux Codex binary is required inside a container, run scripts/build_codex_linux_binary.py and mount the result into AMS.
  3. Validate with curl-based smoke tests (HTML, /api/agent-sdk/list, SSE endpoints, start/stop).

Bundled Resources

  • Step-by-step playbook: references/agentic_ecosystem_docker_playbook.md
  • Linux Codex builder helper: scripts/build_codex_linux_binary.py