diff --git a/app/models/cluster.js b/app/models/cluster.js index b87eef2b5..97b645837 100644 --- a/app/models/cluster.js +++ b/app/models/cluster.js @@ -231,10 +231,9 @@ export default Resource.extend(Grafana, ResourceUsage, { return 'custom'; } - return firstPool.driver || get(firstPool, 'nodeTemplate.driver') || null; default: - if (get(this, 'driver') && get(this, 'configName')) { + if (get(this, 'driver')) { return get(this, 'driver'); } else { return 'import'; @@ -247,6 +246,7 @@ export default Resource.extend(Grafana, ResourceUsage, { const pools = get(this, 'nodePools'); const firstPool = (pools || []).objectAt(0); const configName = get(this, 'configName'); + const driverName = get(this, 'driver'); switch ( configName ) { case 'amazonElasticContainerServiceConfig': @@ -280,8 +280,13 @@ export default Resource.extend(Grafana, ResourceUsage, { return intl.t('clusterNew.custom.shortLabel'); } default: - if (get(this, 'driver') && get(this, 'configName')) { - return get(this, 'driver').capitalize(); + if (driverName) { + switch (driverName) { + case 'rancherd': + return intl.t('clusterNew.rancherd.shortLabel'); + default: + return driverName.capitalize(); + } } else { return intl.t('clusterNew.import.shortLabel'); } diff --git a/translations/en-us.yaml b/translations/en-us.yaml index a27b61f6b..f21b9fd40 100644 --- a/translations/en-us.yaml +++ b/translations/en-us.yaml @@ -4182,6 +4182,8 @@ clusterNew: quick: Quick Create custom: Custom Create existing: Existing + rancherd: + shortLabel: RancherD rke: upgradeStrategy: