Select Page
by

Shashank Srivastava

|
last updated on June 16, 2022
Share

Introduction

Modern software delivery demands that infrastructure should be automated, and delivery must be continuous. Spinnaker and Terraform are two outstanding open-source tools that complement each other and play an important role in the software delivery value chain . The former is a Continuous Delivery (CD) tool, and the latter is an infrastructure provisioning automation tool, also called infrastructure as code. 

What is Terraform? 

Terraform is an open-source platform developed by HashiCorp that enables users to safely and predictably create, change, and manage infrastructure. It allows developers, DevOps engineers, and site reliability engineers (SREs)s to codify infrastructure configurations into standard files that can be shared among team members and treated as code that can be edited, reviewed, and versioned. 

How does Terraform work?

Terraform works as an infrastructure versioning and management tool. It keeps track of the planned (desired) infrastructure and the current state infrastructure in a state file. When there is a need or something changes in the live infrastructure, Terraform can compare the state file with the desired state of the infrastructure. It can then take action or call the required Application Programming Interface (APIs) to match the desired state. 

Why integrate Terraform with a CD tool?

Prior to Continuous Delivery, teams would roll out updates late at night to avoid any customer traffic into the infrastructure. During this planned downtime, application services will also be brought down to implement the necessary changes. But as services have become available 24/7,companies strive to avoid downtime by implementing Continuous Delivery practices to roll out updates safely and automatically. Code updates can be delivered as they are ready, rather than having to wait until low user traffic periods. 

What is Spinnaker?

Spinnaker is a multi-cloud Continuous Delivery platform for releasing software changes. It is designed to increase release velocity and reduce the risk associated with updating applications. Spinnaker is used in production by thousands of organizations worldwide to automate their software delivery process and used by developers, testers, and SREs to deploy hundreds of changes a day.

Why integrate Terraform with Spinnaker?

Prior to Continuous Delivery, teams would roll out updates late at night to avoid disruptions tocustomer traffic.. During this planned downtime, application services will also be brought down to implement the necessary changes. But as services have become available 24/7,companies strive to avoid downtime by implementing Continuous Delivery practices to roll out updates safely and automatically. Code updates can be delivered as they are ready, rather than having to wait until low user traffic periods. 

Terraform can automate the configuration of your cloud provider. One can describe any aspect of the cloud suite providers to ensure that the desired state of infrastructure can be spun up whenever required. But Terraform struggles in achieving Continuous Deployment. 

For example, if you are hosting UAT(User Acceptance Teating), staging and production on Google Cloud Platform, you want the changes made on Terraform to be automatically tested and deployed. Unfortunately, it will not be possible with Terraform alone. We will need an internalcontroller or orchestrator to handle the CD framework.

Spinnaker + Terraform

Modern infrastructure requirements change within hours and minutes, and sometimes seconds. Spinnaker recognizes that infrastructure is not a static requirement, but a dynamic one. Integrating it with monitoring systems while making changes can help detect issues and bugs. Spinnaker is the open-source CD tool that can promote IAC(Infrastructure as code) changes from environment to environment. It also supports many cloud providers to which it can deploy natively.

Benefits of Using Terraform with Spinnaker

Coupling Terraform with Spinnaker can benefit organizations in multiple ways. DevOps teams are able to gain increased efficiencies and speed by automating the creation and tear down of the infrastructure during the deployment process, enabling on-demand deployments. Additional benefits include: 

    • Manage and orchestrate Terraform scripts on-demand within Spinnaker.
    • Achieve infrastructure as a code and deploy applications using the same pipeline.
    • Reuse Terraform scripts to build and tear down infrastructure.
    • Teams who have onboarded Spinnaker can create Terraform infrastructure pipelines precisely the same way they create application pipelines. There is a low barrier to adoption and a short, simple learning curve.
    • Terraform operations can rely on the same Spinnaker artifacts and repositories.
    • Establish guardrails for both application code and infrastructure management with Spinnaker. 

As a result of these operational improvements you gain:

    • Faster pace of software delivery with the end-to-end automation. 
    • Increased productivity of dev and ops and SREs team.
    • Reduced infrastructure costs.
    • Reduced dependencies on SREs for trivial and menial work.
Zendesk-and-Symphony-CTA

Why choose OpsMx to integrate with Terraform for your Continuous Deployments

OpsMx Intelligent Continuous Delivery Platform (ISD) is a modern continuous delivery platform based on Spinnaker, designed to safely and securely increase delivery speed without human intervention.  ISD simplifies the building and managing of pipelines to minimize orchestration, integration, and governance. 

OpsMx provides an open-source Terraspin service (and a custom job) that seamlessly integrates Spinnaker. Terraspin allows developers and ops teams to execute Terraform templates or scripts and deploy/destroy infrastructure using Spinnaker deployment pipelines.  

Terraform operations like plan, applying, and destroying infrastructure can be easily orchestrated with OpsMx Platform.

Additional reasons to choose OpsMx Platform over other solutions. 

    • Secure efficiency and cost savings by enabling faster time-to-market with RBAC(Role based access control) and hardened infrastructure.
    • Ensures accuracy and repeatability by applying the same testing stringency to infrastructure code as to application code.
    • Infrastructure documentation will always be current – documentation doesn’t have to be manually recorded when the code itself is the documentation.
    • Enables collaboration across disparate teams. 
    • Visualize your infrastructure rollout and understand the state of your infrastructure at-a-glance.
    • Provision, test, and revise infrastructure in all stages: staging, testing, and production even in air-gapped environments.

OpsMx can seamlessly integrate with Terraform, enabling DevOps teams to extend the power of software pipelines and continuous delivery to infrastructure management. It can roll out infrastructure alongside applications, with the safety and reliability of Spinnaker. 

Conclusion

Organizations adopting both Terraform and Spinnaker can experience a multitude of benefits. Embedding Terraform infrastructure as a code through the same check and review process of the application review process ensures a solid vetting process. The infrastructure gets checked repeatedly for correctness at every step of the software delivery. 

With Spinnaker and Terraform, organizations roll out infrastructure and applications simultaneously, side by side. It enables stakeholders to understand better how the code and infrastructure are related and reduces triage time. 

Watch our webinars on Terraform integration with OpsMx Enterprise for Spinnaker.

Tags :

Shashank Srivastava

As a Country Manager, Sales & Marketing (ROW) at OpsMx, Shashank is responsible for revenue for Europe, Middle East and Asia Pacific. He is also responsible for Product Marketing and Strategic Partnerships. Shashank brings in over 20 years of experience in selling and marketing technology / software solutions. Over these years he has led teams for marketing, sales, business development and field operations. He has successfully driven several strategic initiatives within startup environments.

Link

0 Comments

Submit a Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.