1 | import * as ecr from '@aws-cdk/aws-ecr';
|
2 | import * as secretsmanager from '@aws-cdk/aws-secretsmanager';
|
3 | import { BuildSpec } from './build-spec';
|
4 | import { BuildEnvironment, ComputeType, IBuildImage, ImagePullPrincipalType } from './project';
|
5 | /**
|
6 | * A CodeBuild image running aarch64 Linux.
|
7 | *
|
8 | * This class has a bunch of public constants that represent the CodeBuild ARM images.
|
9 | *
|
10 | * You can also specify a custom image using the static method:
|
11 | *
|
12 | * - LinuxBuildImage.fromEcrRepository(repo[, tag])
|
13 | *
|
14 | *
|
15 | * @see https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-available.html
|
16 | */
|
17 | export declare class LinuxArmBuildImage implements IBuildImage {
|
18 | /** Image "aws/codebuild/amazonlinux2-aarch64-standard:1.0". */
|
19 | static readonly AMAZON_LINUX_2_STANDARD_1_0: IBuildImage;
|
20 | /** Image "aws/codebuild/amazonlinux2-aarch64-standard:2.0". */
|
21 | static readonly AMAZON_LINUX_2_STANDARD_2_0: IBuildImage;
|
22 | /**
|
23 | * Returns an ARM image running Linux from an ECR repository.
|
24 | *
|
25 | * NOTE: if the repository is external (i.e. imported), then we won't be able to add
|
26 | * a resource policy statement for it so CodeBuild can pull the image.
|
27 | *
|
28 | * @see https://docs.aws.amazon.com/codebuild/latest/userguide/sample-ecr.html
|
29 | *
|
30 | * @param repository The ECR repository
|
31 | * @param tagOrDigest Image tag or digest (default "latest", digests must start with `sha256:`)
|
32 | * @returns An aarch64 Linux build image from an ECR repository.
|
33 | */
|
34 | static fromEcrRepository(repository: ecr.IRepository, tagOrDigest?: string): IBuildImage;
|
35 | /**
|
36 | * Uses a Docker image provided by CodeBuild.
|
37 | *
|
38 | * @see https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-available.html
|
39 | *
|
40 | * @param id The image identifier
|
41 | * @example 'aws/codebuild/amazonlinux2-aarch64-standard:1.0'
|
42 | * @returns A Docker image provided by CodeBuild.
|
43 | */
|
44 | static fromCodeBuildImageId(id: string): IBuildImage;
|
45 | readonly type = "ARM_CONTAINER";
|
46 | readonly defaultComputeType = ComputeType.LARGE;
|
47 | readonly imageId: string;
|
48 | readonly imagePullPrincipalType?: ImagePullPrincipalType;
|
49 | readonly secretsManagerCredentials?: secretsmanager.ISecret;
|
50 | readonly repository?: ecr.IRepository;
|
51 | private constructor();
|
52 | /**
|
53 | * Validates by checking the BuildEnvironment computeType as aarch64 images only support ComputeType.SMALL and
|
54 | * ComputeType.LARGE
|
55 | * @param buildEnvironment BuildEnvironment
|
56 | */
|
57 | validate(buildEnvironment: BuildEnvironment): string[];
|
58 | runScriptBuildspec(entrypoint: string): BuildSpec;
|
59 | }
|