Skip to content

breaking: remove servieaccount auth mode - #175

Merged
openshift-merge-bot[bot] merged 1 commit into
rhobs:mainfrom
andreasgerstmayr:remove-serviceaccount-auth-mode
Jul 23, 2026
Merged

breaking: remove servieaccount auth mode#175
openshift-merge-bot[bot] merged 1 commit into
rhobs:mainfrom
andreasgerstmayr:remove-serviceaccount-auth-mode

Conversation

@andreasgerstmayr

Copy link
Copy Markdown
Contributor

The kubeconfig auth mode already reads the mounted service account token in case kubeconfig is not found.

@andreasgerstmayr
andreasgerstmayr requested a review from a team July 22, 2026 13:34
@openshift-ci
openshift-ci Bot requested review from rexagod and tremes July 22, 2026 13:34
@coderabbitai

coderabbitai Bot commented Jul 22, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@andreasgerstmayr, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 51 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews.

How do review limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please refer docs for additional details.

Review details
⚙️ Run configuration

Configuration used: Repository YAML (base), Organization UI (inherited)

Review profile: CHILL

Plan: Pro Plus

Run ID: 473c1c49-72c1-4a25-a8f6-3d3bf9e41ac3

📥 Commits

Reviewing files that changed from the base of the PR and between 7a4e1be and 1434c8d.

📒 Files selected for processing (9)
  • README.md
  • cmd/obs-mcp/main.go
  • cmd/obs-mcp/main_test.go
  • docs/DEPLOYMENT.md
  • manifests/core/deploy/openshift/configmap.yaml
  • manifests/prometheus/deploy/openshift/rbac.yaml
  • pkg/auth/auth.go
  • pkg/auth/token.go
  • tests/e2e/openshift_e2e_test.go
📝 Walkthrough

Walkthrough

The supported authentication modes now consist of kubeconfig and header; service-account authentication parsing and direct token-file loading were removed. Kubeconfig may use local or mounted credentials. Loki URL resolution now uses the CLI flag or LOKI_URL, without route or auth-mode fallback. Documentation, manifests, and OpenShift test comments were updated accordingly.

Estimated code review effort: 3 (Moderate) | ~20 minutes

Suggested reviewers: rexagod, tremes

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly matches the main change: removing the serviceaccount auth mode as a breaking change.
Description check ✅ Passed The description is directly related to the change and explains why serviceaccount mode can be removed.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@andreasgerstmayr
andreasgerstmayr force-pushed the remove-serviceaccount-auth-mode branch from d76684e to 7a4e1be Compare July 22, 2026 14:09
Comment thread cmd/obs-mcp/main.go Outdated
Comment thread README.md Outdated
@@ -85,7 +85,7 @@ go run ./cmd/obs-mcp/ --listen 127.0.0.1:9100 --auth-mode kubeconfig --metrics-b
> 2. `LOKI_URL` environment variable
> 3. Default: `http://localhost:3100` (kubeconfig mode only)

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.

needs to be updated as well. It seems the logic is simpler now: it's wither the --loki-url/LOKI_URL or discovery, regardless of the auth method, right?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

yep, updated in #177

Comment thread README.md Outdated
> 3. Default: `http://localhost:3100` (kubeconfig mode only)
>
> In `header` and `serviceaccount` modes, you can either set `--loki-url`/`LOKI_URL` **or** use LokiStack discovery (`loki_list_instances` + `lokiNamespace`/`lokiName` arguments).
> In `header` mode, you can either set `--loki-url`/`LOKI_URL` **or** use LokiStack discovery (`loki_list_instances` + `lokiNamespace`/`lokiName` arguments).

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.

This would now work in all modes it seems? I approved #177, let's wait for that and rebase with resolved conflicts.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

You're right. I reworked the entire box now, and also added one for Tempo.

The kubeconfig auth mode already reads the mounted service account token
in case kubeconfig is not found.

Signed-off-by: Andreas Gerstmayr <agerstmayr@redhat.com>
@andreasgerstmayr
andreasgerstmayr force-pushed the remove-serviceaccount-auth-mode branch from 7a4e1be to 1434c8d Compare July 23, 2026 13:52
@openshift-ci

openshift-ci Bot commented Jul 23, 2026

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: andreasgerstmayr, iNecas

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:
  • OWNERS [andreasgerstmayr,iNecas]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-merge-bot
openshift-merge-bot Bot merged commit 9939e52 into rhobs:main Jul 23, 2026
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants