How Cloudify Integrates with Chef
There are many common challenges today for your everyday dev and ops tasks:
- Configuration management
- Server provisioning
- Application deployment
- Monitoring of deployed tiers
In addition to some nice to have functionality, such as multi-region resilience and multi-cloud enablement. This is where known DevOps tools come in. There are quite a few common configuration management tools to help you setup your environment. Cloudify integrates natively with the two most common CM tools – Chef and Puppet. This is a quick how-to guide for how to use Chef with Cloudify.
Cloudify natively integrates with Chef. Try it out. Go
Chef For Noobs
For those unfamiliar with Chef, it is an open-source configuration management tool, essentially an automation platform built to address the most difficult infrastructure challenges. It provides rapid provisioning and deployment of servers for automated delivery of applications and services, at scale, as well. The user writes “recipes” that describe how a Chef manages server applications (such as Apache, MySQL, or Hadoop) and how they are to be configured. These recipes describe a series of resources that should be in a particular state – packages that should be installed, services that should be running, or files that should be written. Chef makes sure each resource is properly configured, and automatically discovers data points of the system. Chef takes care of the configuration management challenge quite well.
Cloudify + Chef
While Chef is a great configuration management tool that can save a lot of time and prevent many mistakes in application deployment, most dev and ops folks face more than just these challenges. Some of these include: VMs provisioning in the pre-deployment phase, and monitoring and scaling in the post deployment phase. This is where Cloudify integrates with Chef to manage the entire application lifecycle.
Partnered with Chef, Cloudify allows your application to concentrate on doing what it does best, by ensuring that the resources it needs are available regardless of the cloud and stack used. Cloudify provides the cloud orchestration that takes care of provisioning VMs, networks, block storage, and such, that you need in the cloud. Using Chef, the lifecycle of services can be simplified as Chef takes care of keeping service configurations up-to-date with current specifications as defined by roles and cookbooks. In order to use Chef cookbooks for service installation, Cloudify provides a configurable base Chef recipe that does most of the Chef bootstrapping work. Typically you will only need to extend this recipe and take care of the pre and post deployment phases that Chef doesn’t handle.
The Basic Flow
Monitoring of deployed tiers and auto scaling
Use Case – How to Achieve Continuous Delivery with Chef and Cloudify
A typical deployment is usually comprised of a number of artifacts that include configuration management, monitoring configuration, custom scripts to deal with availability, SLAs, and integration with third-party components. This leads to a high degree of complexity, especially in a continuously changing environment such as a fast-paced continuous delivery model – with this type of delivery model, such a modus operandi is just not sustainable.
What needs to be done in order to enable continuous delivery is to consolidate all of the different artifacts into a single blueprint, which then becomes the “single-source of truth” for the entire stack. This coupled with a cloud orchestration engine, in this case Cloudify, that can parse that blueprint and execute the definitions defined therein through a single command to create a fully consistent environment – for example between staging and production. This includes the configuration, application binaries and all its dependencies, as well as post-deployment SLAs. This provides a single-source for updating changes to the application blueprints ands SLAs themselves, such as updating monitoring and management metrics, high availability policies, failure detection policies and configuration changes. With this the technology is then selected from predefined menus that are defined by architecture and are delivered by platform, where the configuration is fully automated with the use of Chef as the configuration management tool.
The build process can then be consolidated into a single build pipeline that is agnostic of the technology stack and language runtime, through Cloudify’s custom commands. These custom commands enable continuous interaction with a live system, in the post-deployment phase, for upgrades and shipping of new code to production.
The full how-to guide on the Chef integration with Cloudify can be found in our wiki.