OpenClaw DevOps Operator
Reviews supplied service, container, or log snapshots, with an optional read-only local systemd snapshot workflow.
- Input
- A supplied JSON snapshot or an explicitly selected systemd unit
- Output
- A health attention/unknown result with evidence indices and collection provenance when available.
What it does
- Returns structured findings with evidence references
- Can collect status and logs for an explicitly selected systemd unit
- Does not mutate services or containers; supplied evidence freshness is unknown
Overview
OpenClaw DevOps Operator is a read-only Python 3.11+ diagnostic CLI that analyzes a user-supplied JSON snapshot of service states, container metadata, and log signals to surface actionable incident findings like failed units or port conflicts. It never restarts services or mutates containers, omits raw log contents from reports, and keeps all remediation under explicit operator approval.
When to use it
- Triaging failed systemd services, port conflicts, and container snapshots into a structured JSON health report.
- Letting an AI operations assistant analyze infrastructure evidence without giving it restart or shell-mutation privileges.
- Producing clean stdout or --output diagnostic summaries that omit raw log payloads.
Diagnose service and container evidence
Needs Python 3.11 or newer and only the standard library. Run from the package directory with a JSON snapshot of service state, containers and log lines that you supply.
python3 scripts/devops_operator.py evidence.jsonSample output
Abridged output from version 0.1.0, run on a small synthetic fixture.
{
"status": "ok",
"health": "attention",
"findings": [
{
"code": "SERVICE_NOT_ACTIVE",
"evidence": "service.active_state=failed",
"next_step": "Review unit status and recent logs before approving any restart."
},
{
"code": "PORT_IN_USE",
"next_step": "Correlate these historical log signals with current status and timestamps before approving a change."
}
],
"actions_executed": []
}Exit codes and limits
- Supplied evidence is not checked for freshness or authenticity. Invalid evidence exits 2.
- No service or container is restarted or changed.
- Read-only systemd collection for one unit is opt-in with --collect-unit; Docker is analyzed from supplied evidence only.
- Reports go to stdout unless you ask for a new file with --output, and they omit raw log contents.
Questions
Does OpenClaw DevOps Operator restart failed services or containers?
No. It is strictly read-only—no service or container is restarted or modified, and actions_executed is always empty.
How does it inspect systemd units or Docker containers?
By default it reads a JSON evidence snapshot you supply. Read-only systemd collection for a single unit is opt-in via --collect-unit, while Docker is analyzed from supplied evidence only.
Are raw log lines copied into the output report?
No. Reports are written to stdout (or a new file via --output) and omit raw log contents.
Does it verify that the supplied evidence snapshot is fresh?
No. Supplied evidence is not checked for freshness or authenticity, and invalid evidence exits with code 2.