@hashicorp
The docker plugin can be used with HashiCorp Packer to manage containers with Docker.
- Official
Updated 4 months ago
- GitHub(opens in new tab)
Docker
The Docker plugin is intended to be used for managing docker images through Packer.
Installation
To install this plugin, copy and paste this code into your Packer configuration, then run packer init
.
Alternatively, you can use packer plugins install
to manage installation of this plugin.
Components
Builders
- docker - The builder builds Docker images using Docker. The builder starts a Docker container, runs provisioners within this container, then exports the container for reuse or commits the image.
Post-Processors
docker-import - The import post-processor takes an artifact from the docker builder and imports it with Docker locally.
docker-push - The push post-processor takes an artifact from the docker-import post-processor and pushes it to a Docker registry.
docker-save - The save post-processor takes an artifact from the docker builder that was committed and saves it to a file.
docker-tag - The tag post-processor takes an artifact from the docker builder that was committed and tags it into a repository.