Agent skill · hashicorp
push-to-registry
Push Packer build metadata to HCP Packer registry for tracking and managing image lifecycle. Use when integrating Packer builds with HCP Packer for version control and governance.
What it needs
About 2k tokens when loaded.
What this skill does
Push to HCP Packer Registry Configure Packer templates to push build metadata to HCP Packer registry. Reference: HCP Packer Registry Note: HCP Packer is free for basic use. Builds push metadata only (not actual images), adding minimal overhead (<1 minute). Basic Registry Configuration Authentication Set environment variables before building: Create HCP Service Principal 1. Navigate to HCP → Access Control (IAM) 2. Create Service Principal 3. Grant "Contributor" role on project 4. Generate client secret 5. Save client ID and secret Registry Configuration Options bucketname (required) The image identifier. Must stay consistent across builds! bucketlabels (optional) Metadata at bucket level. Updates with each build. buildlabels (optional) Metadata for each iteration. Immutable after build completes. CI/CD Integration GitHub Actions Querying in Terraform Common Issues Authentication Failed Verify HCPCLIENTID and HCPCLIENTSECRET Ensure service principal has Contributor role Check organization and project IDs Bucket Name Mismatch Keep bucketname consistent across builds Don't include timestamps in bucketname Creates new bucket if name changes Build Fails Packer fails immediately if can't push metadata Prevents drift between artifacts and registry Check network connectivity to HCP API Best Practices Consistent bucket names - Never change for same image type Meaningful labels - Use for versions, teams, compliance CI/CD automation - Automate builds and registry pushes Immutable build labels - Put changing data (git SHA, date) in buildlabels References HCP Packer Documentation hcppackerregistry Block HCP Terraform Provider
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills hashicorp/push-to-registry--c086b7