Devops Tools Pipeline, Chef versus Puppet

A basic flow of the devops pipeline might look like

Git—>Jenkins—>Puppet/Chef/Ansible—>Jenkins—>Nagios—>Docker/VM

  1. GIT – Developers develop the code and this source code is managed by Version Control System tools like Git etc.
  2. Jenkins pulls this code from the repository using the Git plugin and build it using tools like Ant or Maven.
  3. Puppet, Chef – Configuration management tools like puppet deploys & provisions testing environment and then Jenkins releases this code on the test environment on which testing is done using tools like selenium.
  4. Jenkins – Once the code is tested, Jenkins send it for deployment on the production server (even production server is provisioned & maintained by tools like puppet).
  5. Nagios – After deployment, continuous monitoring by tools like Nagios.
  6. Docker containers provides testing environment to test the build features.

Configuration Managers

Configuration managers provide an abstraction layer between a machine’s raw configuration and its desired state by focusing on users’ goals instead of the tedious tasks necessary to achieve them.

For example, let’s assume you need the “First Ethernet interface to be configured with IPv4 address of 10.0.0.1”

Such high-level instructions can be written as source code — in some cases, it is data rather than code, but let’s keep it simple — and can be stored in a version control repository along with the rest of the application’s code. This, in turn, allows for easier reproducibility and better insight into how the infrastructure should behave.

Chef versus Puppet

One of the biggest differences is how resources are described:

  • Puppet uses a declarative language that is similar to JSON or XML. You describe the resource’s state but cannot intervene in how this state is achieved.
  • Chef uses an imperative language. This means you more or less have full-featured Ruby at your disposal.

The declarative nature of Puppet may seem constraining, but those constraints are usually for your own good. They challenge you to describe the desired state better as opposed to writing complicated procedures that soon become unreadable.

To use an analogy, using Puppet is like writing configuration files whereas using Chef is like programming the control of your nodes. If you or your team have more experience with system administration, you may prefer Puppet. On the other hand, if most of you are developers, Chef might be a better fit.

Client Server Mode

As shown below, both generally work in client-server mode, meaning that one or more machines (running servers) manage the configuration of the other machines using agents. Each of the agents is managed by controlled nodes, either as a system service or periodically (such as from cron).

chef configuration

Jenkins

Defacto Build Automation Tool

Templates for AWS and Azure

  • Azure Templates. Azure Resource Manager templates provide similar JSON template-based resource management capabilities to the AWS CloudFormation service.

  • In each of these interfaces, the resource group is central to how Azure resources get created, deployed, or modified. This is similar to the role a “stack” plays in grouping AWS resources during CloudFormation deployments.

Cloud Advisory Services | Security Advisory Services | Data Science Advisory and Research

Specializing in high volume web and cloud application architecture, Anuj Varma’s customer base includes Fortune 100 companies (dell.com, British Petroleum, Schlumberger).

All content on this site is original and owned by AdverSite Web Holdings, Inc. – the parent company of anujvarma.com. No part of it may be reproduced without EXPLICIT consent from the owner of the content.

Anuj Varma – who has written posts on Anuj Varma, Technology Architect.


Leave a Reply

Your email address will not be published. Required fields are marked *