Skip to content

Cherry-pick #44118: Don't throw gitops-exceptions-related errors on Free tier - #44130

Merged
lukeheath merged 1 commit into
rc-minor-fleet-v4.84.0from
sgress454/gitops-exceptions-free-tier-cp
Apr 24, 2026
Merged

Cherry-pick #44118: Don't throw gitops-exceptions-related errors on Free tier#44130
lukeheath merged 1 commit into
rc-minor-fleet-v4.84.0from
sgress454/gitops-exceptions-free-tier-cp

Conversation

@sgress454

Copy link
Copy Markdown
Contributor

Cherry-pick of #44118 into the RC branch.

Conflict resolution: kept the RC branch's updated error message wording (with server URL link and v4.84 phrasing) and wrapped the three exception checks in the appConfig.License.IsPremium() guard from #44118.

<!-- Add the related story/sub-task/bug number, like Resolves #123, or
remove if NA -->
**Related issue:** Resolves #44098

We set the "secrets" exception on for all new instances (and the label
exception for existing instances), but you can't turn them off in the
free tier. That means GitOps runs (including the one we use to
initialize new instances) would fail with the "you can't use this key
because the exception is on" error. This PR fixes the issue by not
enforcing that rule for free tier instances.

If some of the following don't apply, delete the relevant line.

- [ ] Changes file added for user-visible changes in `changes/`,
`orbit/changes/` or `ee/fleetd-chrome/changes`.
See [Changes
files](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/guides/committing-changes.md#changes-files)
for more information.
n/a, unreleased

- [X] Added/updated automated tests
- [X] added test verifying that the free tier can run gitops using
excepted keys w/out error, and verified that it fails on main and passes
on this branch
- [X] QA'd all new/changed functionality manually
  - [X] spun up a new free-tier server successfully

For unreleased bug fixes in a release candidate, one of:

- [X] Confirmed that the fix is not expected to adversely impact load
test results

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

* **Bug Fixes**
* GitOps exception enforcement no longer blocks free-tier users;
enforcement is applied only for premium licenses, allowing GitOps
applies on free tiers.
* **Tests**
* Added an integration test validating free-tier GitOps behavior to
prevent regressions.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@sgress454
sgress454 requested a review from a team as a code owner April 24, 2026 15:49

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Claude Code Review

This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.

Tip: disable this comment in your organization's Code Review settings.

@sgress454

Copy link
Copy Markdown
Contributor Author

Cherry-pick had conflicts b/c we changed the error messages in 4.85.0. This PR preserves the 4.84-specific error messages while applying the fix.

@codecov

codecov Bot commented Apr 24, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (rc-minor-fleet-v4.84.0@5835276). Learn more about missing BASE report.

Additional details and impacted files
@@                    Coverage Diff                    @@
##             rc-minor-fleet-v4.84.0   #44130   +/-   ##
=========================================================
  Coverage                          ?   68.62%           
=========================================================
  Files                             ?     1546           
  Lines                             ?   178904           
  Branches                          ?        0           
=========================================================
  Hits                              ?   122773           
  Misses                            ?    43631           
  Partials                          ?    12500           
Flag Coverage Δ
backend 68.62% <100.00%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@lukeheath
lukeheath merged commit ec76eec into rc-minor-fleet-v4.84.0 Apr 24, 2026
49 of 51 checks passed
@lukeheath
lukeheath deleted the sgress454/gitops-exceptions-free-tier-cp branch April 24, 2026 17:48
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