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,
|
||||
clusterTemplateRevision: null,
|
||||
applyClusterTemplate: null,
|
||||
weaveDeprecated: false,
|
||||
|
||||
windowsSupportOverrideAvailable: false,
|
||||
|
||||
|
|
@ -64,6 +65,8 @@ export default Component.extend({
|
|||
this._super(...arguments);
|
||||
|
||||
this.setFlannelLables();
|
||||
|
||||
this.checkWeaveDeprecation();
|
||||
},
|
||||
|
||||
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() {
|
||||
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')) {
|
||||
set(this, 'config.network.weaveNetworkProvider', null);
|
||||
}
|
||||
|
||||
this.checkWeaveDeprecation();
|
||||
}
|
||||
}),
|
||||
|
||||
|
|
@ -158,4 +167,13 @@ export default Component.extend({
|
|||
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}}
|
||||
</CheckOverrideAllowed>
|
||||
|
||||
{{#if weaveDeprecated}}
|
||||
{{#banner-message color="bg-warning"}}
|
||||
<p>{{t 'clusterNew.rke.network.banners.weaveDeprecation' htmlSafe=true}}</p>
|
||||
{{/banner-message}}
|
||||
{{/if}}
|
||||
</div>
|
||||
|
||||
{{!-- disabled for now --}}
|
||||
|
|
|
|||
|
|
@ -4706,6 +4706,8 @@ clusterNew:
|
|||
monitoring:
|
||||
label: Metrics Server Monitoring
|
||||
network:
|
||||
banners:
|
||||
weaveDeprecation: The Weave CNI plugin is deprecated as of Kubernetes 1.27 and will be removed in 1.30
|
||||
calico: Calico
|
||||
canal: Canal
|
||||
detail: Configure the networking for the cluster
|
||||
|
|
|
|||
Loading…
Reference in New Issue