Merge pull request #3203 from westlywright/cluster.templates.bugs

Private Registry and Share Member Bugs
This commit is contained in:
Westly Wright 2019-08-07 14:53:54 -07:00 committed by GitHub
commit 60e829aa46
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 18 additions and 13 deletions

View File

@ -269,6 +269,11 @@ export default InputTextFile.extend(ManageLabels, ClusterDriver, {
hideQuestion hideQuestion
}); });
if (path.includes('rancherKubernetesEngineConfig.privateRegistries[0]')) {
// need to replace the array target with built in first object so the alias works
path = path.replace('[0]', '.firstObject');
}
defineProperty(question, 'default', alias(`primaryResource.${ path }`)); defineProperty(question, 'default', alias(`primaryResource.${ path }`));
clusterTemplateQuestions.pushObject(question); clusterTemplateQuestions.pushObject(question);
@ -1220,7 +1225,7 @@ export default InputTextFile.extend(ManageLabels, ClusterDriver, {
this.notifyPropertyChange('initialNodeCounts'); this.notifyPropertyChange('initialNodeCounts');
}); });
if (this.isEdit && this.cluster.appliedSpec) { if (this.isEdit && !isEmpty(get(this, 'cluster.appliedSpec.rancherKubernetesEngineConfig.kubernetesVersion'))) {
initialVersion = this.cluster.appliedSpec.rancherKubernetesEngineConfig.kubernetesVersion; initialVersion = this.cluster.appliedSpec.rancherKubernetesEngineConfig.kubernetesVersion;
} }

View File

@ -8,7 +8,6 @@ import {
} from '@ember/object'; } from '@ember/object';
import { alias, gt } from '@ember/object/computed'; import { alias, gt } from '@ember/object/computed';
import { inject as service } from '@ember/service'; import { inject as service } from '@ember/service';
import { scheduleOnce } from '@ember/runloop';
export default Component.extend({ export default Component.extend({
globalStore: service(), globalStore: service(),
@ -34,7 +33,6 @@ export default Component.extend({
init() { init() {
this._super(...arguments); this._super(...arguments);
scheduleOnce('afterRender', () => {
set(this, 'config', get(this, `cluster.${ get(this, 'configName') }`)); set(this, 'config', get(this, `cluster.${ get(this, 'configName') }`));
if (this.config.privateRegistries) { if (this.config.privateRegistries) {
@ -45,7 +43,6 @@ export default Component.extend({
}); });
} }
} }
});
}, },
actions: { actions: {

View File

@ -22,6 +22,7 @@
@pagingLabel="pagination.cluster" @pagingLabel="pagination.cluster"
@headers={{membersHeaders}} @headers={{membersHeaders}}
@stickyHeader={{false}} @stickyHeader={{false}}
@search={{false}}
as |sortable kind member dt| as |sortable kind member dt|
> >
{{#if (eq kind "row")}} {{#if (eq kind "row")}}

View File

@ -859,7 +859,9 @@ C.CLUSTER_TEMPLATE_IGNORED_OVERRIDES = [
'rancherKubernetesEngineConfig.network.options.flannel_backend_vni', 'rancherKubernetesEngineConfig.network.options.flannel_backend_vni',
'rancherKubernetesEngineConfig.network.plugin', 'rancherKubernetesEngineConfig.network.plugin',
'rancherKubernetesEngineConfig.network.weaveNetworkProvider', 'rancherKubernetesEngineConfig.network.weaveNetworkProvider',
'rancherKubernetesEngineConfig.privateRegistries[]', 'rancherKubernetesEngineConfig.privateRegistries[0].url',
'rancherKubernetesEngineConfig.privateRegistries[0].user',
'rancherKubernetesEngineConfig.privateRegistries[0].password',
'rancherKubernetesEngineConfig.services.etcd.backupConfig.enabled', 'rancherKubernetesEngineConfig.services.etcd.backupConfig.enabled',
'rancherKubernetesEngineConfig.services.etcd.backupConfig.intervalHours', 'rancherKubernetesEngineConfig.services.etcd.backupConfig.intervalHours',
'rancherKubernetesEngineConfig.services.etcd.backupConfig.retention', 'rancherKubernetesEngineConfig.services.etcd.backupConfig.retention',