6 Testing Packer

In the last few chapters we’ve seen how to build images with Packer. Part of that process is provisioning images with the configuration you need. When you’re running scripts, or even using configuration management tools, there’s some risk that the outcomes of your build won’t be what you requested. We can ensure that what we get what we’ve asked for by using software-based tests.

Software tests validate that your software does what it is supposed to do. They are the bread-and-butter validation tools of developers. Loosely, they’re a combination of quality measures and correctness measures. We’re going to apply some of the principles of software testing to our infrastructure. A software unit test, at its heart, confirms that ...

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.