HashiCorp Packer
$ packer Official Med RiskHashiCorp Packer (packer) builds identical machine images (AMIs, GCP images, Azure VHDs, Docker images) from HCL2 templates, offering packer validate syntax/config checks, packer inspect, -color=false, and -machine-readable CSV logs.
brew install hashicorp/tap/packer packer validates HCL2 templates and runs local/cloud image builds directly from repo definitions.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Supports -machine-readable CSV logs, -color=false, and packer validate, though lacks modern -json output.
- Supports
-machine-readable,-color=false, andpacker validate
packer validate and inspect are safe pre-flight checks, while build creates real cloud VMs/images.
- Safe
validateandinspectprior topacker build
Single static Go binary via Homebrew or official releases across macOS, Linux, and Windows.
- Single Go binary via
brew install hashicorp/tap/packer
Standardizes golden-image pipelines across AWS, GCP, Azure, and VMware.
- Multi-cloud golden image automation
Official hashicorp/packer repository maintained under BSL-1.1.
- Official
hashicorp/packerrepository
Thorough HashiCorp Developer CLI and plugin documentation.
- Docs at developer.hashicorp.com/packer
Security, Auth & Guardrails
Inherits cloud builder credentials from environment variables or standard provider profiles (AWS_*, GOOGLE_APPLICATION_CREDENTIALS, ARM_*).
CLI is free under BSL-1.1; packer build creates temporary cloud VMs and persisted machine images.
# Packer Agent Rules - Always run `packer fmt -check` and `packer validate` before `packer build`. - Pass `-color=false` (or `-machine-readable`) in automated logs. - Remember `packer build` spins up real temporary cloud VMs and snapshots—require approval first.
Agent-Ready Command Recipes
Safe Read-Only Queries
packer validate -syntax-only .
Checks HCL2 syntax without downloading plugins or contacting cloud APIs.
packer inspect -machine-readable .
Outputs template variables, builders, and provisioners in comma-separated machine-readable lines.
Strengths for Agents
- +
packer validateandpacker fmt -checkverify templates cleanly offline/locally. - + Fast single Go binary with
-color=falseand-machine-readableflags. - + Supports HCL2 variables, plugins (
packer init), and multi-cloud builders.
Caveats & Pitfalls
- !
-machine-readableemits legacy CSV format rather than JSON. - !
packer builddoes not have a--dry-runmode and can take 10–30 minutes to complete.