Over the last few weeks I’ve put together a pull request for Packer which should be releasing soon with version 0.5.2.
With my usage of Packer and Docker, I’ve always found it an annoyance to have to import the Packer built Docker image separately, using Docker import, rather than have Packer handle importing with a post-processor.
Once 0.5.2 releases, the deployment of a Packer built Docker image can be optimized through the use of the docker-push and docker-import post processors, through a build template with post-processors much like the following: