Repository navigation
🤖 docs: add GitOps health rules for CoderMCPServer - #383
Merged
Merged
Conversation
Refs #155 Change-Id: I78243fc7daa13e78d19d85d38db9b09d434f7696 Signed-off-by: Thomas Kosiewski <tk@coder.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
Member
Author
|
@codex security review |
🛡️ Codex Security ReviewSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Argo CD and Flux can now wait for a
CoderMCPServer. This PR adds the health rules inconfig/gitops/and copies them into the CoderMCPServer how-to, as #212 did forCoderTemplateTest. I moved them out of #381 to keep that PR near 500 lines.The rules
Both rules wait until
status.observedGenerationequalsmetadata.generation. Then they read the conditions:observedGenerationProgressingInProgress(Unknownbefore the first status)Reconciling=TrueProgressingInProgressReady=TrueHealthyCurrentStalled=TrueDegradedFailedThe Argo CD message is
<reason>: <message>of theReadycondition. While the object is being deleted, Argo CD showsDeleting the Coder MCP server config.config/gitops/argocd-health-codermcpserver.lua: theargocd-cmkeyresource.customizations.health.coder.com_CoderMCPServer.config/gitops/flux-healthcheck-codermcpserver.yaml: an entry forspec.healthCheckExprsof a Flux v2.5+ Kustomization withspec.wait: true.docs/how-to/manage-mcp-servers.md: a new section "GitOps health checks" with both rules.Validation
config/gitops/health_test.gonow runs one table per kind. The CoderMCPServer cases use reasons that the controller sets:Applied,ControlPlaneNotReady,CoderUnavailable,GroupNotFound,MCPServersNotAllowed,DisabledExternally,CredentialNotOptedIn,SlugConflict, plus no status, a stale generation, no conditions, and two deletion cases. Both the Lua script (gopher-lua) and the Flux CEL expressions run against every case.TestDocCopiesRuleschecks that the how-to copies equal the files.failedset tofalse, and a doc copy that drifts each make a test fail.make verify-vendor,make build,make lint,GOFLAGS=-mod=vendor go tool govulncheck ./...,make test,make test-integration,go test -race ./internal/controller/, andmake docs-checkpass.make codegen,make manifests,make build-installerandmake docs-referenceleave no diff.Size
251 changed lines: 37 in the two rule files, 154 in the test (mostly the per-kind table), 60 in the how-to.
Refs #155
Generated with
xum• Model:anthropic:claude-opus-5-5• Thinking:high• Cost:$224.47