Skip to content

Fix master builds #331

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
Open

Fix master builds #331

wants to merge 9 commits into from

Conversation

Julien-Ben
Copy link
Collaborator

@Julien-Ben Julien-Ben commented Aug 11, 2025

Summary

Master patches are broken because they build with latest tag only, while the patch still need the patch_id tagged images.
This PR fixes this issue to get master green again, but remove builds to latest.
They will be added again in #317, using build_info.
Not pushing to latest only impacts local testing for dev, as we use them to have the most recently built versions from master. It won't break local development, but it means the image used will be slightly outdated.

Proof of Work

I tested it by forcing to return the patch ID and dumping the relevant variables in this patch:
https://spruce.mongodb.com/version/6899d033f94ad4000694cf89/tasks?sorts=STATUS%3AASC%3BBASE_STATUS%3ADESC

But the relevant environment variable (is_patch being false, as described in the added documentation) will be set to the right value only when merging to master.

Copy link

⚠️ (this preview might not be accurate if the PR is not rebased on current master branch)

MCK 1.3.0 Release Notes

Bug Fixes

  • This change fixes the current complex and difficult-to-maintain architecture for stateful set containers, which relies on an "agent matrix" to map operator and agent versions which led to a sheer amount of images.
  • We solve this by shifting to a 3-container setup. This new design eliminates the need for the operator-version/agent-version matrix by adding one additional container containing all required binaries. This architecture maps to what we already do with the mongodb-database container.

Other Changes

  • Optional permissions for PersistentVolumeClaim moved to a separate role. When managing the operator with Helm it is possible to disable permissions for PersistentVolumeClaim resources by setting operator.enablePVCResize value to false (true by default). When enabled, previously these permissions were part of the primary operator role. With this change, permissions have a separate role.
  • subresourceEnabled Helm value was removed. This setting used to be true by default and made it possible to exclude subresource permissions from the operator role by specifying false as the value. We are removing this configuration option, making the operator roles always have subresource permissions. This setting was introduced as a temporary solution for this OpenShift issue. The issue has since been resolved and the setting is no longer needed.

@Julien-Ben Julien-Ben marked this pull request as ready for review August 11, 2025 13:39
@Julien-Ben Julien-Ben requested a review from a team as a code owner August 11, 2025 13:39
@MaciejKaras MaciejKaras added the skip-changelog Use this label in Pull Request to not require new changelog entry file label Aug 11, 2025
Copy link
Collaborator

@MaciejKaras MaciejKaras left a comment

Choose a reason for hiding this comment

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

LGTM

@@ -71,10 +86,12 @@ def get_version(self) -> str:
return self.git_tag
if self.scenario == BuildScenario.STAGING:
# On master merges, always use "latest" (preserving legacy behavior)
return "latest"
return self.patch_id
Copy link
Collaborator

Choose a reason for hiding this comment

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

The comment is not valid anymore, right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

That's correct, good catch
Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip-changelog Use this label in Pull Request to not require new changelog entry file
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants