Packer allows us to create machine images using a number of builders — including LXC images! By using the LXC builder, we can use `lxc` (or lxc1 — not LXD) to create gzipped images of the root file system that we can later deploy using operating system-level virtualization. In this hands-on lab, we’ll prepare a web image with Packer and LXC.
Learning Objectives
Successfully complete this lab by achieving the following learning objectives:
- Write the Packer Template
- Move into the
packer/booksite
directory. - Write the template based on the provided instructions.
- Move into the
- Test the Build
- Validate the JSON.
- Test the build.