Skip to content

fix: Correctly migrate SECRET_KEY from 26.3 setups#754

Merged
sbernauer merged 7 commits into
mainfrom
fix/secret-key-migration
Jul 13, 2026
Merged

fix: Correctly migrate SECRET_KEY from 26.3 setups#754
sbernauer merged 7 commits into
mainfrom
fix/secret-key-migration

Conversation

@sbernauer

@sbernauer sbernauer commented Jul 10, 2026

Copy link
Copy Markdown
Member

Description

Fixes #753

We basically lookup connection.secretKey from the old credentials Secret and use that as the SECRET_KEY. If - for some reason, e.g. fresh setup - it doesn't exist we still create a random value (as we currently do)

We had to revert the credentialsSecret -> credentialsSecretName rename, as otherwise the operator would reconcile the CRD on startup. This would in turn result in the credentialsSecret being dropped, so we loos the information how the old Secret was called.

Definition of Done Checklist

  • Not all of these items are applicable to all PRs, the author should update this template to only leave the boxes in that are relevant
  • Please make sure all these things are done and tick the boxes

Author

  • Changes are OpenShift compatible
  • CRD changes approved
  • CRD documentation for all fields, following the style guide.
  • Helm chart can be installed and deployed operator works
  • Integration tests passed (for non trivial changes)
  • Changes need to be "offline" compatible
  • Links to generated (nightly) docs added
  • Release note snippet added -> In feat: Add generic database connection mechanism #722 (comment)

Reviewer

  • Code contains useful comments
  • Code contains useful logging statements
  • (Integration-)Test cases added
  • Documentation added or updated. Follows the style guide.
  • Changelog updated
  • Cargo.toml only contains references to git tags (not specific commits or branches)

Acceptance

  • Feature Tracker has been updated
  • Proper release label has been added
  • Links to generated (nightly) docs added
  • Release note snippet added
  • Add type/deprecation label & add to the deprecation schedule
  • Add type/experimental label & add to the experimental features tracker

@sbernauer sbernauer moved this to Development: Waiting for Review in Stackable Engineering Jul 10, 2026
@NickLarsenNZ NickLarsenNZ moved this from Development: Waiting for Review to Development: In Review in Stackable Engineering Jul 10, 2026
@NickLarsenNZ NickLarsenNZ self-requested a review July 10, 2026 11:10
Comment thread rust/operator-binary/src/crd/mod.rs Outdated
NickLarsenNZ
NickLarsenNZ previously approved these changes Jul 10, 2026

@NickLarsenNZ NickLarsenNZ left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, a few nit picks.

Comment thread rust/operator-binary/src/controller.rs
Comment thread CHANGELOG.md Outdated
@sbernauer

Copy link
Copy Markdown
Member Author

@sbernauer

Copy link
Copy Markdown
Member Author

Tests passed, did some manual upgrade testing

@sbernauer sbernauer enabled auto-merge July 10, 2026 13:02
@sbernauer sbernauer changed the title fix: Correctly migrate SECRET_KEY from 26.3 setups fix: Correctly migrate SECRET_KEY from 26.3 setups Jul 10, 2026

@Techassi Techassi left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Mostly lgtm, just two minor comments.

Comment thread rust/operator-binary/src/controller.rs Outdated
Comment thread rust/operator-binary/src/controller.rs
sbernauer and others added 2 commits July 13, 2026 08:40
@sbernauer sbernauer requested review from NickLarsenNZ and Techassi and removed request for NickLarsenNZ July 13, 2026 06:42
@sbernauer sbernauer added this pull request to the merge queue Jul 13, 2026
Merged via the queue into main with commit 62464b9 Jul 13, 2026
18 checks passed
@sbernauer sbernauer deleted the fix/secret-key-migration branch July 13, 2026 07:19
@Techassi Techassi moved this from Development: In Review to Development: Done in Stackable Engineering Jul 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Development: Done

Development

Successfully merging this pull request may close these issues.

26.3 -> 0.0.0-dev SECRET_KEY rotation breaks stacklet

3 participants