-
Notifications
You must be signed in to change notification settings - Fork 519
fix: reinforce MCR migration during upgrade for older clusters #3625
fix: reinforce MCR migration during upgrade for older clusters #3625
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: jackfrancis The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
if o.KubernetesConfig.KubernetesImageBase == cloudSpecConfig.KubernetesSpecConfig.KubernetesImageBase && | ||
o.KubernetesConfig.KubernetesImageBaseType == common.KubernetesImageBaseTypeGCR { | ||
if (o.KubernetesConfig.KubernetesImageBase == "" || o.KubernetesConfig.KubernetesImageBase == cloudSpecConfig.KubernetesSpecConfig.KubernetesImageBase) && | ||
(o.KubernetesConfig.KubernetesImageBaseType == "" || o.KubernetesConfig.KubernetesImageBaseType == common.KubernetesImageBaseTypeGCR) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chreichert this additional tolerance for empty (""
) KubernetesImageBaseType
will fix your issue.
t.Fatalf("defaults flow did assign the expected KubernetesImageBaseType value, got %s, expected %s", properties.OrchestratorProfile.KubernetesConfig.KubernetesImageBaseType, common.KubernetesImageBaseTypeMCR) | ||
} | ||
|
||
// Upgrade scenario forces GCR to MCR - empty KubernetesImageBaseType |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chreichert this unit test proves that during upgrade older clusters w/ an empty KubernetesImageBaseType
will be marked for conversion to an MCR configuration.
Codecov Report
@@ Coverage Diff @@
## master #3625 +/- ##
=======================================
Coverage 73.14% 73.14%
=======================================
Files 147 147
Lines 25165 25165
=======================================
Hits 18408 18408
Misses 5623 5623
Partials 1134 1134
Continue to review full report at Codecov.
|
Reason for Change:
This PR adds additional defaults enforcement for landing on MCR during upgrade, especially for old clusters that don't have newer api model data properties.
Issue Fixed:
Fixes #3618
Requirements:
Notes: