Skip to content

GetImage

Source: src/AWS/ImageBuilder/GetImage.ts

Runtime binding for imagebuilder:GetImage.

Reads an image build version by ARN — its state (BUILDING, AVAILABLE, CANCELLED, FAILED, …) and the AMIs/containers it produced. Build versions are created dynamically by pipeline runs, so this is an account-level binding: pass the imageBuildVersionArn returned by StartImagePipelineExecution or found via ListImagePipelineImages. Provide the implementation with Effect.provide(AWS.ImageBuilder.GetImageHttp).

// init — account-level binding, no resource argument
const getImage = yield* AWS.ImageBuilder.GetImage();
// runtime
const { image } = yield* getImage({ imageBuildVersionArn });
yield* Effect.log(`build is ${image?.state?.status}`);