"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.LinuxArmBuildImage=void 0;var jsiiDeprecationWarnings=()=>{var tmp=require("../../.warnings.jsii.js");return jsiiDeprecationWarnings=()=>tmp,tmp};const JSII_RTTI_SYMBOL_1=Symbol.for("jsii.rtti");var compute_type_1=()=>{var tmp=require("./compute-type");return compute_type_1=()=>tmp,tmp},environment_type_1=()=>{var tmp=require("./environment-type");return environment_type_1=()=>tmp,tmp},image_pull_principal_type_1=()=>{var tmp=require("./image-pull-principal-type");return image_pull_principal_type_1=()=>tmp,tmp},is_lambda_compute_type_1=()=>{var tmp=require("./is-lambda-compute-type");return is_lambda_compute_type_1=()=>tmp,tmp},run_script_linux_build_spec_1=()=>{var tmp=require("./private/run-script-linux-build-spec");return run_script_linux_build_spec_1=()=>tmp,tmp};class LinuxArmBuildImage{static[JSII_RTTI_SYMBOL_1]={fqn:"aws-cdk-lib.aws_codebuild.LinuxArmBuildImage",version:"2.256.1"};static AMAZON_LINUX_2_STANDARD_1_0=LinuxArmBuildImage.fromCodeBuildImageId("aws/codebuild/amazonlinux2-aarch64-standard:1.0");static AMAZON_LINUX_2_STANDARD_2_0=LinuxArmBuildImage.fromCodeBuildImageId("aws/codebuild/amazonlinux2-aarch64-standard:2.0");static AMAZON_LINUX_2_STANDARD_3_0=LinuxArmBuildImage.fromCodeBuildImageId("aws/codebuild/amazonlinux2-aarch64-standard:3.0");static AMAZON_LINUX_2023_STANDARD_2_0=LinuxArmBuildImage.fromCodeBuildImageId("aws/codebuild/amazonlinux-aarch64-standard:2.0");static AMAZON_LINUX_2023_STANDARD_3_0=LinuxArmBuildImage.fromCodeBuildImageId("aws/codebuild/amazonlinux-aarch64-standard:3.0");static fromDockerRegistry(name,options={}){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_codebuild_DockerImageOptions(options)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.fromDockerRegistry),error}return new LinuxArmBuildImage({...options,imageId:name,imagePullPrincipalType:image_pull_principal_type_1().ImagePullPrincipalType.SERVICE_ROLE})}static fromEcrRepository(repository,tagOrDigest="latest"){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_ecr_IRepository(repository)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.fromEcrRepository),error}return new LinuxArmBuildImage({imageId:repository.repositoryUriForTagOrDigest(tagOrDigest),imagePullPrincipalType:image_pull_principal_type_1().ImagePullPrincipalType.SERVICE_ROLE,repository})}static fromCodeBuildImageId(id){return new LinuxArmBuildImage({imageId:id,imagePullPrincipalType:image_pull_principal_type_1().ImagePullPrincipalType.CODEBUILD})}type=environment_type_1().EnvironmentType.ARM_CONTAINER;defaultComputeType=compute_type_1().ComputeType.LARGE;imageId;imagePullPrincipalType;secretsManagerCredentials;repository;constructor(props){this.imageId=props.imageId,this.imagePullPrincipalType=props.imagePullPrincipalType,this.secretsManagerCredentials=props.secretsManagerCredentials,this.repository=props.repository}validate(buildEnvironment){try{jsiiDeprecationWarnings().aws_cdk_lib_aws_codebuild_BuildEnvironment(buildEnvironment)}catch(error){throw process.env.JSII_DEBUG!=="1"&&error.name==="DeprecationError"&&Error.captureStackTrace(error,this.validate),error}const ret=[];return buildEnvironment.computeType&&(0,is_lambda_compute_type_1().isLambdaComputeType)(buildEnvironment.computeType)&&ret.push(`ARM images do not support Lambda ComputeTypes, got ${buildEnvironment.computeType}`),ret}runScriptBuildspec(entrypoint){return(0,run_script_linux_build_spec_1().runScriptLinuxBuildSpec)(entrypoint)}}exports.LinuxArmBuildImage=LinuxArmBuildImage;
