The IT industry has made infrastructure automation a core part of its business. What is infrastructure automation? And why is it important?
In the old days, expanding an existing infrastructure was a tedious task. It took weeks, sometimes months, to procure the hardware and configure it according to the needs. Automation has become more important with the advent of cloud computing and virtualization. Provisioning additional servers to scale up infrastructure is no longer a tedious or time-consuming task. Cloud computing services make it easy to provision a server with the desired configuration in just a few minutes. Where does infrastructure automation come in?
It is no longer just a matter of a few servers. There are hundreds to thousands of them (thanks to the cloud computing model and affordable internet). There are many tasks such as maintenance, deployments, patching, configuration changes, and patches to be applied. These tasks can be time-consuming and error-prone if performed manually on large numbers of servers. What if all of these actions could be scripted and applied to these servers? This will speed up the entire process and allow you to use the same script for multiple servers. It will also increase agility in the overall development process. Infrastructure automation allows you to automate the steps of configuring servers, installing operating systems, and communicating with them. You have many options to achieve this goal, including Chef, Puppet and SaltStack, Ansible and Juju. This post will focus on the basics of Chef.
Chef is an open-source automation platform that Opscode (now known under Chef) developed. It transforms your infrastructure into code, which means that it can now be versionable, tested and repeatable just like application code. This allows for the integration of both the development and operations teams. Any member of either team can now make changes to code, paving the way to continuous integration, delivery, and deployment. It was developed in Ruby and is used by many companies, including Bloomberg, Facebook, GE Capital and RackSpace.
Chef automates the process of building, managing, and deploying infrastructure. It can be either on-premises or in the cloud. It supports a variety operating systems, including AIX, RHEL/CentOS and FreeBSD. Three components make up Chef.
Chef Server
Nodes for Chef
Chef Nodes can be physical or virtual machines, or a server instance hosted in a cloud. These nodes come with Chef Client installed. This allows them to perform the actual configuration and communicate with Chef Server.
It is a machine that users use to perform all configuration-related tasks, such as creating cookbooks that contain policy and configuration details for bringing a node in a certain state, updating Chef repository, and interfacing with nodes.
Chef Server
Chef Server is a hub for configuration data. It stores the policies, cookbooks, and metadata that describe each registered node. Chef Client communicates to the Chef Server to get the configuration details that will be applied to the nodes.
There are two types:
Enterprise Chef
Open Source Chef
Enterprise Chef Server can be used on-premises or as a hosted service.
Hosted Chef
Hosted Chef is a hosted version of Chef Server that is available to enterprises. It is highly scalable, and it is also easily accessible. Users don’t have to worry about maintenance or updates