Add support for AWS Elastic Container Registry (ECR)
Add example for Google Container Registry (GCR)
This commit is contained in:
7
src/ecr.ts
Normal file
7
src/ecr.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
export const isECR = async (registry: string): Promise<boolean> => {
|
||||
return registry.includes('amazonaws');
|
||||
};
|
||||
|
||||
export const getRegion = async (registry: string): Promise<string> => {
|
||||
return registry.substring(registry.indexOf('ecr.') + 4, registry.indexOf('.amazonaws'));
|
||||
};
|
||||
Reference in New Issue
Block a user