ensure eksconfig display name always matches cluster name

rancher/rancher#29353
This commit is contained in:
Westly Wright 2020-10-14 15:00:52 -07:00
parent 82599b011c
commit 10ea146135
No known key found for this signature in database
GPG Key ID: 4FAB3D8673DC54A3
1 changed files with 4 additions and 0 deletions

View File

@ -711,6 +711,10 @@ export default Resource.extend(Grafana, ResourceUsage, {
if (isEmpty(this.id)) {
sanitizeConfigs(eksClusterConfigSpec, nodeGroupConfigSpec);
if (this.name !== get(this, 'eksConfig.displayName')) {
set(this, 'eksConfig.displayName', this.name);
}
return this._super(...arguments);
} else {
const config = jsondiffpatch.clone(get(this, 'eksConfig'));