Skip to content

feat!: cloudfall runs entirely on treaty; MCP server is cloudfall mcp serve - #14

Merged
romamo merged 5 commits into
mainfrom
treaty-complete
Oct 3, 2026
Merged

romamo merged 5 commits into
mainfrom
treaty-complete

Conversation

@romamo

@romamo romamo commented Oct 3, 2026

Copy link
Copy Markdown
Collaborator

Finishes the move off argparse. Every cloudfall command, root --help/--version/--schema, and the MCP server now run on treaty 1.0.0rc29.

CLI

  • operator run streams one event per watch pass, with data.pass and data.effect (treaty #175). The loop moved into operator.watch()
  • dashboard serve streams one event once it listens, then serves until stopped. Request lines go through ctx.log
  • changelog is treaty's built-in, served from a packaged schema-changelog.json. It is generated at release time with treaty changelog-add, as described in CONTRIBUTING
  • cli.py just calls app.run. arguments.py, manifest.py and output.py are deleted, along with their tests
  • The AGENTS.md that cloudfall init writes describes treaty's envelope
  • operator run is listed with the commands that change servers, since a declared OperatorPolicy lets it run proposals

MCP: cloudfall-mcp becomes cloudfall mcp serve

Uses treaty #239, #240, #281 and #285, filed for this port.

  • The tools are the commands, chosen per mode (--project or --repository)
  • The fleet, schema and engine directories, and the evidence directories commands share, are bound for the run. They leave the tool schemas, and a call that passes one is refused
  • Provided tools:
    • Project mode: build_artifact, and converge_baseline/services/domains. The converges are destructive and need confirm_destructive
    • Repository mode: one operation_* tool per declared operation, which runs check mode and records a proposal
  • init, operations approve, operator run and dashboard serve are mcp=False
  • mcp_server.py, fleet_tools.py and AgentToolset are deleted. AgentConfig stays for migrate

Breaking for callers

  • MCP clients run cloudfall mcp serve instead of cloudfall-mcp. Tool names follow the commands, for example list_operations becomes operations_list
  • operator_approve, backup_run and backup_verify run in one call over MCP. They were confirm-gated before
  • operator_watch is gone
  • Stopping operator run exits 143 on SIGTERM. A systemd unit needs SuccessExitStatus=143 (the operator guide has it)
  • operator approve reports an unusable gateway as 4 PRECONDITION and an unreachable one as 12 UNAVAILABLE

Checks

  • ruff check . and mypy are clean
  • pytest: 353 passed. This includes stdio end-to-end MCP tests in test_agent_server.py and a subprocess test of dashboard serve
  • treaty audit has no new findings beyond the empty schema changelog

Treaty bugs found along the way: #288 (stdout stand-in lacks reconfigure()) and #289 (UNKNOWN_TOOL omits provided tools).

🤖 Generated with Claude Code

romamo and others added 5 commits October 3, 2026 16:57
…l mcp serve`

The last argparse commands move to treaty 1.0.0rc29:

- `operator run` streams one event per watch pass, with `effect` per pass
  (treaty #175); the loop is `operator.watch()`, testable with a fake feed
- `dashboard serve` streams one event once it listens, then serves until
  stopped; request lines go through ctx.log
- `changelog` is treaty's built-in, from a packaged schema-changelog.json
- root --help, --version and --schema are treaty's; cli.py calls app.run,
  and arguments.py, manifest.py and output.py are gone

`cloudfall-mcp` becomes `cloudfall mcp serve` (treaty #239, #240, #281,
#285): the tools are the commands, chosen per fleet mode, with the fleet,
schema, engine and shared evidence directories bound for the run. Engine
work without a command (build_artifact, converge_*) and one tool per
declared operation are provided tools. init, operations approve, operator
run and dashboard serve are never MCP tools. mcp_server.py, fleet_tools.py
and AgentToolset are gone; stdio end-to-end tests cover the server.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… gateway URL

A project-mode call could name api_url and api_key_file together and send
any controller file as the bearer key to a host of its choosing, write
decrypted values to any path through secrets_render's output_file, or point
operator_approve's verification at its own gateway.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The startup flag was read as a secret, so --secrets-dir was refused and
only --secrets-dir-from-env/--secrets-dir-from-file were offered, unlike
cloudfall-mcp and the secrets guide.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ger has

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… directory

A project-mode tool call could name an absolute receipts, output_dir,
env_dir or plan_file path and write outside the project: an import's env
files hold the application's real values. Binding needs one field name per
directory, so the CLI flags that named the same directory differently are
renamed: observe --output-dir is --observed, services inspect --output-dir
is --service-observed, and --receipts is --releases, --backups,
--data-migrations or --env-receipts by what it holds. A non-default
--observed or --env-receipts now reaches observe and secrets render too.

dashboard serve reports only a failed bind as dashboard_listen_failed; the
eager snapshot read is no longer caught as one.

The site and fleet-goals no longer call every MCP write confirm-gated.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@romamo
romamo merged commit f105109 into main Oct 3, 2026
1 check passed
@romamo
romamo deleted the treaty-complete branch October 3, 2026 14:28
@shipmill-romamo shipmill-romamo Bot added this to the 0.6.0 milestone Oct 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant