×
Community Blog Managing Infrastructure as Code (IaC) on Alibaba Cloud

Managing Infrastructure as Code (IaC) on Alibaba Cloud

This article gives an overview of how to manage Infrastructure as Code (IaC) on Alibaba Cloud.

By Ankit Mehta

What Is Infrastructure as Code (IaC)?

In the early days of cloud offering, services were limited, so it was easy to create and destroy resources from the console. However, console-based resource creation is error-prone, and even one wrong step can compromise complete cloud infrastructure or make applications fail to work. Also, even with precisely similar instructions, one cannot guarantee an identical environment.

Infrastructure as Code (IaC) was created to overcome all these issues. With proper implementation of Infrastructure as Code, users can achieve:

  • Versioned Environment (with Git)
  • Quick Provision
  • Clean and Destroy
  • Desired State Validation and Drift Check

Resource Orchestration Service (ROS)

Alibaba Cloud Resource Orchestration Service (ROS) can help automate Infrastructure as Code and deployment with simple YAML files. ROS supports almost all the resources offered by Alibaba Cloud, including the most popular services like Elastic Compute Service (ECS), Relational Database Service (RDS), and Server Load Balancer (SLB).

ROS is a free offering that includes a mix and match of console usage and IaC. ROS provides cloud best practices configurations in template format, and these templates help cloud engineers to adapt IaC efficiently. Users can trigger ROS deployments through APIs or from the console. Also, this comes with advantages, such as visual verification of the deployment and template, deployment history, and trial . A created template can help deploy resources in a different zone, region, or account.

Terraform

Terraform is another popular IaC tool that allows cloud engineers to use HashiCorp Configuration Language for resource provision. As a result, cloud engineers can build Infrastructure as Code quickly for various public cloud providers with no learning curve.

One of the critical segments for any infrastructure as a code is storing the implemented infrastructure details storage. Terraform supports keeping infrastructure details (known as Terraform State files) on Alibaba Cloud Object Storage Service (OSS).

Terraform connects with Alibaba Cloud API and can provision, de-provision, or edit existing cloud resources. In addition, Alibaba Cloud ROS supports Terraform natively, which allows end-users to deploy resources from the Alibaba Cloud Console directly.

Pulumi

Pulumi has been gaining popularity for the last couple of years to help provision Infrastructure as Code due to its simplicity and feature richness. Users can implement and deploy Infrastructure as Code with popular programming languages, such as Node.Js, Python, Go, or .NET core.

Ansible

Ansible is a leading configuration management tool. However, Ansible can also help provision Infrastructure as Code. Ansible configuration uses YAML for infrastructure definition.

Crossplane

Crossplane helps provision infrastructures using Kubernetes. Crossplane uses the YAML configuration to provision resources.

Conclusion

There are multiple ways and tools to implement Infrastructure as Code (IaC) strategies for any organization. This article highlighted some of the most popular tools that can help achieve IaC goals on Alibaba Cloud.

1 0 0
Share on

Alibaba Cloud Community

1,076 posts | 263 followers

You may also like

Comments

Charry September 15, 2021 at 7:12 am

Thanks for sharing this post, It was great reading this article. I would like to know more.Also Check This.