hermes-s6-container-supervision

Diagnose s6-overlay supervision behavior for Hermes Agent Docker containers.

Updated May 16, 2026
One-click install
npx skills add https://github.com/jaredcroxton/hermes-mirror --skill hermes-s6-container-supervision
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: hermes-s6-container-supervision
Source: https://github.com/jaredcroxton/hermes-mirror/tree/main/agents/skills/software-development/hermes-s6-container-supervision
Command: npx skills add https://github.com/jaredcroxton/hermes-mirror --skill hermes-s6-container-supervision

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It helps you understand and troubleshoot how Hermes uses s6-overlay to supervise per-profile gateways and static services inside the Hermes Agent Docker image, especially when services fail to start, restart correctly, or behave unexpectedly after container restarts.

Core Features & Use Cases

  • Explain the CMD-as-main-program architecture: clarifies how /opt/hermes/docker/main-wrapper.sh interacts with /init under s6-overlay and why the container exit behavior differs from fully supervised setups.
  • Guide static service and gateway troubleshooting: focuses on diagnosing missing or unstable per-profile gateway services in /run/service/ and understanding the reconciliation behavior on each boot.
  • Provide actionable container-level workflows: includes practical inspection, manual start/stop/restart operations, and how to interpret container-boot.log results when reconciling profiles.

Quick Start

Use this skill to debug why a profile gateway service isn’t staying up by inspecting its s6 status in /run/service/gateway-<profile> and correlating behavior with the latest entries in /opt/data/logs/container-boot.log.

Frequently Asked Questions about hermes-s6-container-supervision

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How does s6-overlay supervision work for Docker containers using the CMD main-program pattern?

s6-overlay supervision manages Docker containers by running a main-program wrapper through `/init`, where PID 1 interacts with cont-init.d scripts and the s6-rc service manager to control static services and per-profile gateways.

Why do my per-profile gateway services fail to stay up after a Docker restart?

Gateway services fail after Docker restart when the `02-reconcile-profiles` boot flow encounters errors, causing s6 service registration and rendering to miss gateway slots in `/run/service/gateway-<profile>`. Inspect `container-boot.log` to diagnose the reconciliation failure.

How do I troubleshoot missing s6 static services in my Hermes Agent Docker container?

Troubleshoot missing s6 static services by inspecting `/run/service/` directories for rendered service definitions, checking the s6-rc service manager dispatch rules, and correlating startup behavior with entries in `container-boot.log`.

What is the 02-reconcile-profiles reconciliation flow in s6-overlay container boot?

The `02-reconcile-profiles` flow is a cont-init.d script that maps per-profile gateway slots to s6-rc static services during container boot, ensuring each profile gateway is registered, rendered, and dispatched correctly by the s6 service manager.

Can I manually stop and restart individual s6 gateway services inside a running Docker container?

Yes, you can manually start, stop, and restart individual s6 gateway services inside a running Docker container using s6 service commands targeting the specific `/run/service/gateway-<profile>` directory to control supervision behavior.

When should I not use the CMD main-program wrapper for s6 container supervision?

Avoid the CMD main-program wrapper pattern when you need fully supervised container exit behavior, because this architecture causes the container exit behavior to differ from setups where all processes are strictly supervised by the s6-overlay init system.