mirror of https://github.com/rancher/dashboard.git
More renaming
This commit is contained in:
parent
6c8722e4b5
commit
29486475a1
|
|
@ -884,7 +884,7 @@ cluster:
|
|||
name:
|
||||
label: Cluster Name
|
||||
placeholder: A unique name for the cluster
|
||||
nodeConfig:
|
||||
machineConfig:
|
||||
aws:
|
||||
sizeLabel: |-
|
||||
{apiName}: {cpu}, {memory, number} GiB Memory, {storageSize, plural,
|
||||
|
|
|
|||
|
|
@ -827,7 +827,7 @@ cluster:
|
|||
name:
|
||||
label: 节点池名称
|
||||
placeholder: 默认情况下会随机生成一个节点池名称
|
||||
#nodeConfig:
|
||||
#machineConfig:
|
||||
#aws:
|
||||
#sizeLabel: |-
|
||||
#{apiName}: {cpu}, {memory, number} GiB Memory, {storageSize, plural,
|
||||
|
|
|
|||
|
|
@ -122,7 +122,7 @@ export function init(store) {
|
|||
mapGroup('logging.banzaicloud.io', 'Logging');
|
||||
mapGroup(/.*resources\.cattle\.io.*/, 'Backup-Restore');
|
||||
mapGroup(/^(.*\.)?cluster\.x-k8s\.io$/, 'Cluster Provisioning');
|
||||
mapGroup(/^(aks|eks|gke|rke|rke-node|provisioning)\.cattle\.io$/, 'Cluster Provisioning');
|
||||
mapGroup(/^(aks|eks|gke|rke|rke-machine|provisioning)\.cattle\.io$/, 'Cluster Provisioning');
|
||||
|
||||
configureType(NODE, { isCreatable: false, isEditable: false });
|
||||
configureType(WORKLOAD_TYPES.JOB, { isEditable: false, match: WORKLOAD_TYPES.JOB });
|
||||
|
|
|
|||
|
|
@ -306,7 +306,7 @@ export default {
|
|||
return true;
|
||||
},
|
||||
|
||||
nodeConfigSchema() {
|
||||
machineConfigSchema() {
|
||||
if ( !this.hasMachinePools ) {
|
||||
return null;
|
||||
}
|
||||
|
|
@ -449,8 +449,8 @@ export default {
|
|||
if ( existing?.length ) {
|
||||
for ( const pool of existing ) {
|
||||
const config = await this.$store.dispatch('management/find', {
|
||||
type: `provisioning.cattle.io.${ pool.nodeConfigRef.kind.toLowerCase() }`,
|
||||
id: `${ this.value.metadata.namespace }/${ pool.nodeConfigRef.name }`,
|
||||
type: `provisioning.cattle.io.${ pool.machineConfigRef.kind.toLowerCase() }`,
|
||||
id: `${ this.value.metadata.namespace }/${ pool.machineConfigRef.name }`,
|
||||
});
|
||||
|
||||
// @TODO what if the pool is missing?
|
||||
|
|
@ -470,14 +470,14 @@ export default {
|
|||
},
|
||||
|
||||
async addMachinePool() {
|
||||
if ( !this.nodeConfigSchema ) {
|
||||
if ( !this.machineConfigSchema ) {
|
||||
return;
|
||||
}
|
||||
|
||||
const numCurrentPools = this.machinePools.length || 0;
|
||||
|
||||
const config = await this.$store.dispatch('management/createPopulated', {
|
||||
type: this.nodeConfigSchema.id,
|
||||
type: this.machineConfigSchema.id,
|
||||
metadata: { namespace: DEFAULT_WORKSPACE }
|
||||
});
|
||||
|
||||
|
|
@ -498,8 +498,8 @@ export default {
|
|||
hostnamePrefix: '',
|
||||
labels: {},
|
||||
quantity: 1,
|
||||
nodeConfigRef: {
|
||||
kind: this.nodeConfigSchema.attributes.kind,
|
||||
machineConfigRef: {
|
||||
kind: this.machineConfigSchema.attributes.kind,
|
||||
name: null,
|
||||
},
|
||||
},
|
||||
|
|
@ -542,7 +542,7 @@ export default {
|
|||
const neu = await entry.config.save();
|
||||
|
||||
entry.config = neu;
|
||||
entry.pool.nodeConfigRef.name = neu.metadata.name;
|
||||
entry.pool.machineConfigRef.name = neu.metadata.name;
|
||||
entry.create = false;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ export default {
|
|||
if ( this.isImported ) {
|
||||
return null;
|
||||
} else if ( this.isRke2 ) {
|
||||
const kind = this.spec?.rkeConfig?.machinePools?.[0]?.nodeConfigRef?.kind?.toLowerCase();
|
||||
const kind = this.spec?.rkeConfig?.machinePools?.[0]?.machineConfigRef?.kind?.toLowerCase();
|
||||
|
||||
if ( kind ) {
|
||||
return kind.replace(/config$/i, '').toLowerCase();
|
||||
|
|
|
|||
|
|
@ -146,7 +146,7 @@ export const actions = {
|
|||
groupLabel,
|
||||
instanceClass,
|
||||
memoryBytes: parseSi(row['Memory']),
|
||||
label: rootGetters['i18n/t']('cluster.nodeConfig.aws.sizeLabel', {
|
||||
label: rootGetters['i18n/t']('cluster.machineConfig.aws.sizeLabel', {
|
||||
apiName,
|
||||
cpu: row['vCPUs'],
|
||||
memory: parseInt(row['Memory'], 10),
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ export const actions = {
|
|||
value: size.slug
|
||||
};
|
||||
|
||||
out.label = rootGetters['i18n/t']('cluster.nodeConfig.digitalocean.sizeLabel', out);
|
||||
out.label = rootGetters['i18n/t']('cluster.machineConfig.digitalocean.sizeLabel', out);
|
||||
|
||||
return out;
|
||||
}).filter(size => size.plan !== 'other');
|
||||
|
|
|
|||
Loading…
Reference in New Issue