Infrastructure as Code – The developer’s point of view
This week, we’re going to look at infrastructure from the developer’s point of view. Developers by their nature, see everything as code. We’ll refer to this idea as – Infrastructure as Code.
Infrastructure as Code is the process of leveraging code, or machine-readable files, to manage and provision data center resources in addition to using software development best practices in the management of your data center automation tools. My colleague, David Jasso recently wrote a blog talking about Infrastructure as code as one of the keys to IT remaining relevant among developers.
The Advantages of Infrastructure as Code
There are several advantages to describing your data center infrastructure as code:
- The first key is that the infrastructure can be codified using a high-level syntax. Describing your infrastructure parametrically is intuitive, eases troubleshooting and enables you to link parameters to the menu of choices given to end users when selecting an infrastructure component.
- The second key is that each infrastructure subcomponent can be combined with other standard building blocks, or blueprint elements for higher level blueprints of your services. All of the compute, networking and storage devices can be organized into discrete code elements that are easily reused in multiple blueprint variations. This is a similar concept to creating libraries of functions or subroutines, which are a standard practice in software development.
Blueprints are building blocks
A blueprint can be versioned just as you would any other piece of code by using a version control system and a central repository, such as GitHub. This is yet another standard practice for software developers. Using software development best practices ensures that a blueprint can be automatically tested, validated and even rolled back if necessary. It also enables the opportunity to exploit continuous integration (CI) and continuous delivery (CD) best practices. Both CI and CD help to reduce the overall cost, time and risk of changes to production code and enable more incremental updates to what goes into production. vRealize Automation has not only an impressive list of customers using it but also a proven track record of improving the way the IT operates. Combine that with vRealize Code Stream to enable a more streamlined continuous delivery engine and all of your organizations deployments can be automated and governed throughout the deployment process.
Code is the key
When it comes to defining infrastructure as code, everything needs to be codified into serial components, and currently the most popular language available for this serialization is YAML.
Today vRealize Automation (vRA) allows you to create and manage datacenter blueprints in two ways which are inter-operable:
- Visually formatted through the vRA console using the drag and drop design canvas
- As Code, via blueprints as code using a YAML format
The beauty of a blueprint as code is that the syntax is simple, high-level and easy to learn. A blueprint as code is cloud agnostic, meaning that it will operate on any cloud infrastructure: private, public or hybrid. Blueprints as code cover all of the various elements of your infrastructure including compute, networking and storage resources.
The most important attribute of a blueprint as code is that they are standardized and portable. The portability of blueprint elements or services allow them to be reusable across different deployments and groups, not to mention easily modified to fit a developer’s needs. You can run a YAML blueprint on any platform that supports it. In this way, YAML is standardizing infrastructure management in the way that HTML standardized web page coding.
A blueprint as code also enables the ability for an organization to not only easily modify blueprints but also allows for easy versioning while sharing blueprints across various deployments or environment types (i.e. Dev, Test, Production). In our next blog in this series, we’ll cover how vRealize Automation and vRealize Code Stream can do this for your organization.
If you want to learn more in depth detail about managing your infrastructure as code, check out Kief Morris’s book Infrastructure as Code.
YAML documents are cloud agnostic and can run on any cloud infrastructure. Describing your infrastructure as code enables you to impart software development best practices for your infrastructure management. vRealize Automation fully supports blueprints as code in YAML today.