Skip to content

Commit

Permalink
Merge pull request #5129 from rak-phillip/bugfix/10516-cloud-provider
Browse files Browse the repository at this point in the history
Use `initialCloudProvider` for comparison when upgrading Kubernetes from <1.27
  • Loading branch information
rak-phillip authored Mar 11, 2024
2 parents c38c6a6 + 64b7a3d commit 5f16726
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/shared/addon/components/cru-cloud-provider/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,9 @@ export default Component.extend({

k8sVersionDidChange: observer( 'cluster.rancherKubernetesEngineConfig.kubernetesVersion', function(){
const kubernetesVersion = get(this, 'cluster.rancherKubernetesEngineConfig.kubernetesVersion')
const selectedCloudProvider = get(this, 'selectedCloudProvider')
const initialCloudProvider = get(this, 'initialCloudProvider')

if (selectedCloudProvider === 'amazonec2' && Semver.gte(Semver.coerce(kubernetesVersion), '1.27.0')){
if (initialCloudProvider === 'amazonec2' && Semver.gte(Semver.coerce(kubernetesVersion), '1.27.0')){
set(this, 'unsupportedProviderSelected', true);
set(this, 'selectedCloudProvider', 'external-aws');
set(this, 'showChangedToAmazonExternal', true);
Expand Down

0 comments on commit 5f16726

Please sign in to comment.