imagebuilder-bake-validate

Poll AWS Image Builder builds to terminal state and locate retained builder instances after failures.

Updated Apr 14, 2026
One-click install
npx skills add https://github.com/amitkarpe/agent-skills --skill imagebuilder-bake-validate-amitkarpe
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: imagebuilder-bake-validate
Source: https://github.com/amitkarpe/agent-skills/tree/main/skills/imagebuilder-bake-validate
Command: npx skills add https://github.com/amitkarpe/agent-skills --skill imagebuilder-bake-validate-amitkarpe

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve? Waiting on AWS Image Builder builds and debugging failures requires repetitive console checks and manual evidence gathering. This Skill automates durable polling of image builds to terminal state, captures status evidence to disk, and locates retained EC2 builder instances after failed builds so debugging can start immediately. ## Core Features & Use Cases - Durable build polling: Poll an Image Builder image ARN with status-change logging, writing image.json, status.txt, summary.json, and ami-id.txt to a persistent output directory. - Retained builder discovery: Find the latest EC2 instance tagged with the image build ARN when terminate-on-failure is disabled, enabling SSM-based failure investigation. - Clean exit semantics: Exit codes distinguish AVAILABLE (0), FAILED/CANCELLED (1), and timeout (124) for scripting and handoff. - Use Case: After triggering an Image Builder bake from a repo-native pipeline, run the poll script to wait for completion; on failure, immediately capture the retained builder instance ID and hand off to SSM replay or AMI validation workflows. ## Quick Start Ask the agent to poll your Image Builder image ARN with your AWS profile and region, then find the retained builder instance if the build fails.

Frequently Asked Questions about imagebuilder-bake-validate

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I poll an AWS Image Builder build until it finishes?▼

Run scripts/poll-image.sh with the image build version ARN, AWS profile, and region. It polls every 30 seconds by default, logs status changes, and exits 0 on AVAILABLE, 1 on FAILED or CANCELLED, and 124 on timeout.

How do I find the EC2 instance from a failed Image Builder build?▼

Run scripts/find-retained-builder-instance.sh with the image ARN, profile, and region. It queries EC2 for instances tagged with the Ec2ImageBuilderArn and writes the latest matching instance ID to instance-id.txt.

What evidence files does the Image Builder polling script write?▼

The poll script writes image-arn.txt, image.json, status.txt, status.log, summary.json, and ami-id.txt when an AMI is produced. Files go to a specified output directory or a timestamped default under ~/.AGENTS-temp.

When should I not use this Image Builder workflow?▼

Do not use it for defining repo-specific component YAML, publishing or versioning components, or launched-instance SSM validation. Those belong to repo-native tooling or companion skills like imagebuilder-component-publish and ami-validation-ssm.

Why does the retained builder lookup return no instance?▼

The lookup only finds instances in pending, running, stopping, or stopped states tagged with the image ARN. If the infrastructure configuration terminates builders on failure, no instance is retained and you must rely on CloudWatch logs instead.