Skip to content
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

fix(upgrade): remove version check for rancher-system-agent workaround (backport #4966) #5381

Merged
merged 1 commit into from
Apr 17, 2024

Conversation

mergify[bot]
Copy link

@mergify mergify bot commented Mar 18, 2024

Problem:

Previously, the workaround applied to rancher-system-agent for not restarting RKE2 server/agent remains on the nodes if an upgrade failed after upgrading Harvester charts (in phase 3). This is problematic if an upgrade from v1.1.x to v1.2.x failed, and the user want to start over the upgrade again. This will effectively become an upgrade from v1.2.x to v1.2.x, and the workaround will not be removed in the pre-drain phase because of the version checking.

Solution:

We need RKE2 server/agent to not restart during Rancher upgrade. This is true no matter what version we're upgrading from/to, so changing the workaround applied to rancher-system-agent to be a part of the regular upgrade flow by removing the version checking.

Related Issue:

#5380

Test plan:

  1. Install Harvester v1.1.2
  2. Upgrade to v1.2.1
  3. Monitor the upgrade progress, when the Harvester version becomes v1.2.1, remove the Upgrade CR (to break the upgrade)
  4. Clean up the mess (if any)
  5. Start the upgrade again (upgrade from v1.2.1 to v1.2.1)
  6. The upgrade ends up successfully
  7. There should be no /run/systemd/system/rancher-system-agent.service.d/ directory on the nodes

For QA engineers, the test plan would be:

  1. Install Harvester v1.3-head
  2. Upgrade to v1.3.0-rc3
  3. Intentionally break the upgrade when the Harvester version becomes the new version (by removing the Upgrade CR)
  4. Clean up the mess if there are any unsettled bundles
  5. Start the upgrade again
  6. The upgrade should end successfully
  7. There should be no /run/systemd/system/rancher-system-agent.service.d/ directory on the nodes
    This is an automatic backport of pull request fix(upgrade): remove version check for rancher-system-agent workaround #4966 done by Mergify.

We need RKE2 server/agent to not restart during Rancher upgrade. This
is true no matter what version we're upgrading from/to, so changing the
workaround applied to RSA (rancher-system-agent) to be a part of the
regular upgrade flow by removing the version checking.

Signed-off-by: Zespre Chang <zespre.chang@suse.com>
(cherry picked from commit 804669f)
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 24.96%. Comparing base (12242b9) to head (72668f0).
Report is 10 commits behind head on v1.2.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##             v1.2    #5381      +/-   ##
==========================================
+ Coverage   24.60%   24.96%   +0.36%     
==========================================
  Files          88       89       +1     
  Lines       10616    10714      +98     
==========================================
+ Hits         2612     2675      +63     
- Misses       7719     7748      +29     
- Partials      285      291       +6     

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

@starbops starbops merged commit a78bffb into v1.2 Apr 17, 2024
4 checks passed
@mergify mergify bot deleted the mergify/bp/v1.2/pr-4966 branch April 17, 2024 00:45
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.

4 participants