Skip to content

Document audit, k8s export, and image verification CLI flags#936

Merged
danbarr merged 4 commits into
mainfrom
docs-cli-run-flags-gaps
Jun 12, 2026
Merged

Document audit, k8s export, and image verification CLI flags#936
danbarr merged 4 commits into
mainfrom
docs-cli-run-flags-gaps

Conversation

@danbarr

@danbarr danbarr commented Jun 12, 2026

Copy link
Copy Markdown
Collaborator

Description

This fills three high-priority CLI flag gaps from issue #654 in the Run MCP servers guide. It documents audit logging on thv run (explaining the difference between --enable-audit for built-in defaults and --audit-config for a custom config file, what events are captured, where they go, and the audit config fields), adds the thv export --format k8s option alongside the existing JSON export (including the generated MCPServer manifest and the secrets, OIDC, and telemetry settings that must be configured separately when deploying with the operator), and documents the --image-verification flag with its warn/enabled/disabled values, warn default, and behavior for servers with and without provenance information. Every flag name, accepted value, default, field name, and described behavior was verified against the ToolHive source and the auto-generated CLI reference.

Type of change

  • Documentation update

Related issues/PRs

Addresses #654 (high-priority gaps # 2 audit logging, # 5 export to Kubernetes, # 6 image verification)

🤖 Generated with Claude Code

Fill three high-priority CLI flag gaps from issue #654 in the
Run MCP servers guide:

- Audit logging: explain --enable-audit (built-in defaults) versus
  --audit-config (custom config file), what events are captured,
  where events go, and the audit config fields.
- Export to Kubernetes: document thv export --format k8s alongside
  the existing JSON export, including the MCPServer manifest output
  and the secrets, OIDC, and telemetry settings that must be
  configured separately.
- Image verification: document the --image-verification flag, its
  warn/enabled/disabled values, the warn default, and the behavior
  for servers with and without provenance information.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 12, 2026 03:20
@vercel

vercel Bot commented Jun 12, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs-website Ready Ready Preview, Comment Jun 12, 2026 4:08am

Request Review

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the ToolHive CLI “Run MCP servers” guide to close documentation gaps around three high-priority thv flags/options: audit logging on thv run, Kubernetes YAML export via thv export --format k8s, and container image verification behavior via --image-verification.

Changes:

  • Added a new “Enable audit logging” section documenting --enable-audit and --audit-config, including an example audit config file and guidance on payload capture.
  • Added a new “Verify container image signatures” section documenting --image-verification modes (warn|enabled|disabled) and expected behavior.
  • Expanded the “Export a server configuration” section to cover --format (json|k8s), including a sample MCPServer manifest and operator-related follow-ups (secrets/OIDC/telemetry).

Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Comment thread docs/toolhive/guides-cli/run-mcp-servers.mdx Outdated
Apply Copilot review comments: name the eventTypes/excludeEventTypes
audit fields and use a writable logFile path, clarify that either audit
flag enables logging, fix the image-verification note contradiction,
clarify thv export operates on an existing workload, and correct the
Kubernetes secrets guidance to reference spec.secrets.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@danbarr

danbarr commented Jun 12, 2026

Copy link
Copy Markdown
Collaborator Author

Thanks @copilot-pull-request-reviewer, all seven comments were addressed in 38a55c9:

  • Named the eventTypes / excludeEventTypes audit fields and added eventTypes to the example.
  • Changed the example logFile to a writable relative path and noted it must be writable by the user running thv.
  • Reworded the audit note to "use either flag" and clarified --audit-config enables auditing on its own.
  • Fixed the image-verification note: missing provenance is now framed as a verification failure, so warn and enabled diverge without the earlier "applies only" contradiction.
  • Clarified that thv export operates on an existing workload's saved run configuration.
  • Reframed the Kubernetes export caveat around what thv export doesn't populate (not what the CRD can express), and added that secrets must be referenced via spec.secrets (name, key, optional targetEnvName).

The image verification section implied every registry server includes
provenance information. Clarify that provenance is per-server
(checkable via thv registry info) and note the effect of --image-
verification enabled on servers without it, in neutral terms.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Exporting remote servers to Kubernetes is unsupported because thv
export doesn't handle it, not because the operator can't run remote
servers. The operator supports remote servers via the MCPRemoteProxy
resource. Reword and link to the remote MCP proxy guide.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@danbarr danbarr marked this pull request as ready for review June 12, 2026 04:16
@danbarr danbarr merged commit d02e9c4 into main Jun 12, 2026
4 checks passed
@danbarr danbarr deleted the docs-cli-run-flags-gaps branch June 12, 2026 13:20
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.

3 participants