aws-cdk-lib.aws_codebuild.IBindableBuildImage

interface IBindableBuildImage

LanguageType name
.NETAmazon.CDK.AWS.CodeBuild.IBindableBuildImage
Gogithub.com/aws/aws-cdk-go/awscdk/v2/awscodebuild#IBindableBuildImage
Javasoftware.amazon.awscdk.services.codebuild.IBindableBuildImage
Pythonaws_cdk.aws_codebuild.IBindableBuildImage
TypeScript (source)aws-cdk-lib » aws_codebuild » IBindableBuildImage

Implemented by LinuxGpuBuildImage

A variant of IBuildImage that allows binding to the project.

Properties

NameTypeDescription
defaultComputeTypeComputeTypeThe default ComputeType to use with this image, if one was not specified in BuildEnvironment#computeType explicitly.
imageIdstringThe Docker image identifier that the build environment uses.
typestringThe type of build environment.
imagePullPrincipalType?ImagePullPrincipalTypeThe type of principal that CodeBuild will use to pull this build Docker image.
repository?IRepositoryAn optional ECR repository that the image is hosted in.
secretsManagerCredentials?ISecretThe secretsManagerCredentials for access to a private registry.

defaultComputeType

Type: ComputeType

The default ComputeType to use with this image, if one was not specified in BuildEnvironment#computeType explicitly.


imageId

Type: string

The Docker image identifier that the build environment uses.

See also: https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-available.html


type

Type: string

The type of build environment.


imagePullPrincipalType?

Type: ImagePullPrincipalType (optional, default: ImagePullPrincipalType.SERVICE_ROLE)

The type of principal that CodeBuild will use to pull this build Docker image.


repository?

Type: IRepository (optional, default: no repository)

An optional ECR repository that the image is hosted in.


secretsManagerCredentials?

Type: ISecret (optional, default: no credentials will be used)

The secretsManagerCredentials for access to a private registry.

Methods

NameDescription
bind(scope, project, options)Function that allows the build image access to the construct tree.
runScriptBuildspec(entrypoint)Make a buildspec to run the indicated script.
validate(buildEnvironment)Allows the image a chance to validate whether the passed configuration is correct.

bind(scope, project, options)

public bind(scope: Construct, project: IProject, options: BuildImageBindOptions): BuildImageConfig

Parameters

  • scope Construct
  • project IProject
  • options BuildImageBindOptions

Returns

  • BuildImageConfig

Function that allows the build image access to the construct tree.


runScriptBuildspec(entrypoint)

public runScriptBuildspec(entrypoint: string): BuildSpec

Parameters

  • entrypoint string

Returns

  • BuildSpec

Make a buildspec to run the indicated script.


validate(buildEnvironment)

public validate(buildEnvironment: BuildEnvironment): string[]

Parameters

  • buildEnvironment BuildEnvironment — the current build environment.

Returns

  • string[]

Allows the image a chance to validate whether the passed configuration is correct.