Terraform is an open source infrastructure as code (IaC) tool that defines, provisions, and manages cloud infrastructure through declarative configuration files. In Enterprise Distributed Application Service (EDAS), Terraform supports creating and deploying applications to Elastic Compute Service (ECS) clusters and Container Service for Kubernetes (ACK) clusters.
For general information about Terraform, see HashiCorp Terraform.
How Terraform works
Terraform describes cloud resource topologies, such as virtual machines, storage accounts, and network interfaces, in configuration files. Its command-line interface (CLI) deploys these configurations to Alibaba Cloud and versions every change.
The core workflow has three stages:
Write -- Define EDAS resources and their dependencies in configuration files.
Plan -- Preview the changes Terraform will make before applying them.
Apply -- Provision the infrastructure and deploy applications to EDAS.
Terraform is extensible through providers. The Alibaba Cloud provider (alicloud) connects Terraform to EDAS and other Alibaba Cloud services, so you can manage your entire stack from a single tool. For provider details, see Alibaba Cloud Provider on the Terraform Registry.
Why use Terraform with EDAS
Multi-cloud deployment
Terraform uses the same workflow and similar configuration syntax across cloud providers. If your infrastructure spans Alibaba Cloud, other cloud platforms, and on-premises data centers, Terraform provides a unified approach to managing all of it.
Repeatable environments
Configuration templates define and provision ECS resources in a predictable way. Deploy the same template multiple times to create identical development, test, and production environments, reducing human error and eliminating environment drift.
Infrastructure as code
Use code to manage and maintain your resources. Terraform stores a copy of your current infrastructure state. Every change is tracked, auditable, and shareable with your team.
Reduced development costs
Create development and deployment environments on demand based on your business requirements. Evaluate the cost impact of infrastructure changes before applying them.
Get started
EDAS supports two deployment targets: ECS clusters and ACK clusters. Both paths start with the same installation step.
For Terraform configuration syntax details, see Configuration Syntax.