Skip to content

Commit 1f2a2fe

Browse files
committed
skip check fc region
1 parent d306277 commit 1f2a2fe

4 files changed

Lines changed: 5 additions & 53 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,5 +57,6 @@ __tests__/e2e/custom.debian10/python/code/python
5757
__tests__/e2e/custom/python/code/python
5858
__tests__/e2e/python/code/python
5959
__tests__/e2e/python/code/apt-archives
60+
__tests__/e2e/apt/code/package-lock.json
6061

6162
.env_test

__tests__/e2e/apt/code/package-lock.json

Lines changed: 0 additions & 51 deletions
This file was deleted.

src/base.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ export default class Base {
7272
FC.isCustomContainerRuntime(inputs.props.runtime) &&
7373
!IMAGE_ACCELERATION_REGION.includes(inputs.props.region)
7474
) {
75-
throw new Error(
75+
log.warn(
7676
`The region ${inputs.props.region} does not support custom container image acceleration, please use another region, details: https://help.aliyun.com/zh/fc/product-overview/region-availability`,
7777
);
7878
}

src/interface/region.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import logger from '../logger';
2+
13
enum Region {
24
'cn-hangzhou' = 'cn-hangzhou',
35
'cn-shanghai' = 'cn-shanghai',
@@ -36,7 +38,7 @@ export function checkRegion(r: IRegion): boolean {
3638
throw new Error('Region not specified, please specify --region');
3739
}
3840
if (!RegionList.includes(r)) {
39-
throw new Error(`Invalid region, The allowed regions are ${RegionList}`);
41+
logger.warn(`Invalid region, The allowed regions are ${RegionList}`);
4042
}
4143
return true;
4244
}

0 commit comments

Comments
 (0)