fix(omniroute): fix ndots DNS collision hijacking opencode.ai lookups - #4324
Conversation
Default ndots:5 search-expands "opencode.ai" (1 dot) to "opencode.ai.svc.cluster.local" before trying it as absolute, which exactly matches our own in-namespace opencode Service — every lookup of the real opencode.ai provider was silently resolving to our internal opencode app instead. Explains the persistent opencode 502s/timeouts blamed on the upstream provider. ndots:1 (same pattern as seerr, prowlarr-exporter, etc.) tries the absolute name first. This commit was cut into PR #4323 too late to be included in the merge (pushed 5min after merge); reopening standalone.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🔗 Linked repositories identifiedCodeRabbit considers these linked repositories for cross-repo context during reviews:
📝 WalkthroughWalkthroughThe Omniroute HelmRelease adds pod DNS configuration with ChangesOmniroute DNS configuration
Estimated code review effort: 1 (Trivial) | ~5 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
|
|
Overall Grade |
Security Reliability Complexity Hygiene |
Code Review Summary
| Analyzer | Status | Updated (UTC) | Details |
|---|---|---|---|
| JavaScript | Aug 3, 2026 8:49p.m. | Review ↗ | |
| Shell | Aug 3, 2026 8:49p.m. | Review ↗ |
Important
AI Review is run only on demand for your team. We're only showing results of static analysis review right now. To trigger AI Review, comment @deepsourcebot review on this thread.
@@ spec.template.spec @@
# apps/v1/Deployment/ai/omniroute
! + one map entry added:
+ dnsConfig:
+ options:
+ - name: ndots
+ value: "1"
|
@@ spec.values.defaultPodOptions @@
# helm.toolkit.fluxcd.io/v2/HelmRelease/ai/omniroute
! + one map entry added:
+ dnsConfig:
+ options:
+ - name: ndots
+ value: "1"
|
AI Automated ReviewAnalysis engine: omniroute@http://litellm.ai.svc.cluster.local/v1 (openai) RecommendationApprove. The PR correctly resolves a DNS search-domain collision by setting Change-by-Change Findings
Standards Compliance
Must-Check Items
Unknowns or Needs Verification
|
Summary
opencodeprovider failures in omniroute (previously attributed to the upstreamopencode.aiservice in fix(ai): resolve omniroute reliability issues (DNS collision, timeout race) #4323): defaultndots:5search-expands the external domainopencode.ai(1 dot, < ndots) toopencode.ai.svc.cluster.localbefore trying it as an absolute name. That search-expanded name exactly matches our own in-namespaceopencodeService (ainamespace, unrelated self-hosted app), so every DNS lookup of the real provider was silently hijacked to our internal app instead.dnsConfig.options: ndots=1, the same pattern already used byseerrand the*-exporterapps for this exact class of bug — absolute-looking names try direct resolution first.Test plan
kustomize build kubernetes/apps/ai/omniroute/appclean,dnsConfigpresent in rendered Deploymentdig opencode.ai/ omniroute logs show the real provider resolving instead of10.43.254.109(our internal opencode Service ClusterIP)opencodeprovider connection stops erroringSummary by CodeRabbit