mirror of https://github.com/rancher/ui.git
Show banner that Weave is deprecated for k8s >= 1.27
This commit is contained in:
parent
bea822195e
commit
a68506c54f
|
|
@ -55,6 +55,7 @@ export default Component.extend({
|
||||||
enableNetworkPolicy: null,
|
enableNetworkPolicy: null,
|
||||||
clusterTemplateRevision: null,
|
clusterTemplateRevision: null,
|
||||||
applyClusterTemplate: null,
|
applyClusterTemplate: null,
|
||||||
|
weaveDeprecated: false,
|
||||||
|
|
||||||
windowsSupportOverrideAvailable: false,
|
windowsSupportOverrideAvailable: false,
|
||||||
|
|
||||||
|
|
@ -64,6 +65,8 @@ export default Component.extend({
|
||||||
this._super(...arguments);
|
this._super(...arguments);
|
||||||
|
|
||||||
this.setFlannelLables();
|
this.setFlannelLables();
|
||||||
|
|
||||||
|
this.checkWeaveDeprecation();
|
||||||
},
|
},
|
||||||
|
|
||||||
windowsSupportAvailableDidChange: observer('windowsSupportAvailable', function() {
|
windowsSupportAvailableDidChange: observer('windowsSupportAvailable', function() {
|
||||||
|
|
@ -115,6 +118,10 @@ export default Component.extend({
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
k8sVersionDidChange: observer('config.kubernetesVersion', function() {
|
||||||
|
this.checkWeaveDeprecation();
|
||||||
|
}),
|
||||||
|
|
||||||
networkPluginDidChange: observer('config.network.plugin', function() {
|
networkPluginDidChange: observer('config.network.plugin', function() {
|
||||||
let plugin = get(this, 'config.network.plugin');
|
let plugin = get(this, 'config.network.plugin');
|
||||||
|
|
||||||
|
|
@ -131,6 +138,8 @@ export default Component.extend({
|
||||||
} else if (plugin !== WEAVE && get(this, 'config.network.weaveNetworkProvider.password')) {
|
} else if (plugin !== WEAVE && get(this, 'config.network.weaveNetworkProvider.password')) {
|
||||||
set(this, 'config.network.weaveNetworkProvider', null);
|
set(this, 'config.network.weaveNetworkProvider', null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
this.checkWeaveDeprecation();
|
||||||
}
|
}
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
|
@ -158,4 +167,13 @@ export default Component.extend({
|
||||||
set(flannel, 'label', 'clusterNew.rke.network.flannel');
|
set(flannel, 'label', 'clusterNew.rke.network.flannel');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// Weave networking is deprecated as of Kubernetes 1.27 - show a banner to the user when they select Weave and >= 1.27
|
||||||
|
checkWeaveDeprecation() {
|
||||||
|
const plugin = get(this, 'config.network.plugin');
|
||||||
|
const kubernetesVersion = get(this, 'config.kubernetesVersion');
|
||||||
|
const deprecated = (plugin === WEAVE && gte(coerceVersion(kubernetesVersion), 'v1.27.0'));
|
||||||
|
|
||||||
|
set(this, 'weaveDeprecated', deprecated);
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
|
|
||||||
|
|
@ -33,6 +33,11 @@
|
||||||
{{/input-or-display}}
|
{{/input-or-display}}
|
||||||
</CheckOverrideAllowed>
|
</CheckOverrideAllowed>
|
||||||
|
|
||||||
|
{{#if weaveDeprecated}}
|
||||||
|
{{#banner-message color="bg-warning"}}
|
||||||
|
<p>{{t 'clusterNew.rke.network.banners.weaveDeprecation' htmlSafe=true}}</p>
|
||||||
|
{{/banner-message}}
|
||||||
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{!-- disabled for now --}}
|
{{!-- disabled for now --}}
|
||||||
|
|
|
||||||
|
|
@ -4706,6 +4706,8 @@ clusterNew:
|
||||||
monitoring:
|
monitoring:
|
||||||
label: Metrics Server Monitoring
|
label: Metrics Server Monitoring
|
||||||
network:
|
network:
|
||||||
|
banners:
|
||||||
|
weaveDeprecation: The Weave CNI plugin is deprecated as of Kubernetes 1.27 and will be removed in 1.30
|
||||||
calico: Calico
|
calico: Calico
|
||||||
canal: Canal
|
canal: Canal
|
||||||
detail: Configure the networking for the cluster
|
detail: Configure the networking for the cluster
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue