3 First steps with Packer

Packer’s purpose is building images—so we’re going to start by building a basic image. Packer calls the process of creating an image a build. Artifacts are the output from builds. One of the more useful aspects of Packer is that you can run multiple builds to produce multiple artifacts.

A build is fed from a template. The template is a JSON document that describes the image we want to build—both where we want to build it and what the build needs to contain. Using JSON as a format strikes a good balance between readable and machine-generated.

Note New to JSON? Here’s a good article to get you started. You can also find an online linter to help validate JSON syntax.

To determine what sort of image to build, Packer uses ...

Get The Packer Book now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.