Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions src/entry-public-method/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,12 @@ export default class EntryPublicMethod {
// 处理密钥
if (getSecretKey) {
inputs.credentials = await getCredentials(inputs.credentials, inputs.project?.access);
if (_.isEmpty(inputs.credentials?.AccountID)) {
const access = inputs.project?.access;
const tip = `请使用 s config add --AccountID xxxxx --AccessKeyID xxxxx --AccessKeySecret xxxxx --access ${access || 'default'} -f 强制覆盖旧的密钥,然后重试一次
Please use "s config add --AccountID xxxxx --AccessKeyID xxxxx --AccessKeySecret xxxxx --access ${access || 'default'} -f" to force overwrite the old key, then try again.`;
throw new core.CatchableError('Account id not obtained', tip);
}
}

setDefaultValue(inputs);
Expand All @@ -63,6 +69,12 @@ export default class EntryPublicMethod {
}));
}

// fc组件镜像 trim 左右空格
const image = _.get(inputs, 'props.function.customContainerConfig.image');
if (!_.isEmpty(image)) {
_.set(inputs, 'props.function.customContainerConfig.image', _.trim(image));
}

await InfraAsTemplate.modifyInputs(inputs); // 多环境处理

try {
Expand Down