I am using amazon-ebs builder and then customizing the ami with some additional tool. Next, I need to publish this image to JFrog. I am using docker-import and docker-push in post-processors section, but amazon-ebs builder does not seem to like docker-import and docker-push. It needs docker as a builder. How do I accomplish this?
I read this on Packer’s documentation, this is exactly what I am trying to do:
A major benefit of this is that you can modify builder artifacts using shell-local and pass those modified artifacts into post-processors that may not have worked with the original builder. For example, maybe you want to export a Docker container from an amazon-ebs builder and then use Docker-push to put that Docker container into your Docker Hub account.
An EBS AMI is a snapshot of an entire EC2 instance at the block level, including the operating system. A docker image is just the application and what is needed to run it.
I think you misunderstand the statement you pasted. They are saying if you are running Docker on the EC2 instance then you can export the container image from that host to an external artefact.
Maybe start from the beginning - what are you trying to do?
I am taking a golden ami from our aws account, and adding some tools/software on this image to customize it and publish this image to Jfrog artifactory using packer.
Now I need to figure out a post-processor section (or anything that works) to publish this image to Jfrog.