packer-cn/website/source/intro/use-cases.html.markdown

52 lines
2.2 KiB
Markdown
Raw Normal View History

2013-06-21 14:46:38 -04:00
---
layout: "intro"
page_title: "Use Cases"
prev_url: "/intro/why.html"
2013-06-21 15:18:29 -04:00
next_url: "/intro/platforms.html"
next_title: "Supported Platforms"
2013-06-21 14:46:38 -04:00
---
# Use Cases
By now you should know what Packer does and what the benefits of image
creation are. In this section, we'll enumerate _some_ of the use cases
for Packer. Note that this is not an exhaustive list by any means. There are
definitely use cases for Packer not listed here. This list is just meant
to give you an idea of how Packer may improve your processes.
### Continuous Delivery
Packer is lightweight, portable, and command-line driven. This makes it the
perfect tool to put in the middle of your continuous delivery pipeline. Packer
can be used to generate new machine images for multiple platforms on every
change to Chef/Puppet.
As part of this pipeline, the newly created images can then be launched and
tested, verifying the infrastructure changes work. If the tests pass, you can
be confident that that image will work when deployed. This brings a new level
of stability and testability to infrastructure changes.
### Dev/Prod Parity
Packer helps [keep development, staging, and production as similar as possible](http://www.12factor.net/dev-prod-parity).
Packer can be used to generate images for multiple platforms at the same time.
So if you use AWS for production and VMware (perhaps with [Vagrant](http://www.vagrantup.com))
for development, you can generate both an AMI and a VMware machine using
Packer at the same time from the same template.
Mix this in with the continuous delivery use case above, and you have a pretty
2013-06-21 14:46:38 -04:00
slick system for consistent work environments from development all the
way through to production.
### Appliance/Demo Creation
Since Packer creates consistent images for multiple platforms in parallel,
it is perfect for creating [appliances](http://en.wikipedia.org/wiki/Software_appliance)
and disposable product demos. As your software changes, you can automatically
2013-07-28 10:49:03 -04:00
create appliances with the software pre-installed. Potential users can then
2013-06-21 14:46:38 -04:00
get started with your software by deploying it to the environment of their
choice.
Packaging up software with complex requirements has never been so easy.
Or enjoyable, if you ask me.