Terraform Explorer
Terraform Explorer lets you generate, edit, and run Terraform configuration files online without installing Terraform locally.
Overview
Terraform Explorer is an online tool provided by Alibaba Cloud based on the open-source Terraform version for debugging Terraform configuration files. You can automatically generate and transform configuration files through forms and run Terraform commands directly in the browser.
Features
Terraform configuration files
Terraform configuration files define infrastructure resources as code and are the first step in the IaC workflow. You define Alibaba Cloud resources (such as ECS instances and RDS databases) and their dependencies in a configuration file, and Terraform creates and configures them automatically. Terraform Explorer supports both auto-generation and online editing of configuration files.
|
Feature set |
Feature point |
Feature description |
|
Writing configuration files |
Automatically generating configuration files |
Select a cloud product and resource type, then click "Start Debugging". Terraform Explorer generates a configuration file that you can refine by filling in parameters through the form. |
|
Online editing of configuration files |
Terraform Explorer provides one or more example templates for each resource type. If you do not want to fill in too many parameters or want to create multiple resources, you can select an example template after selecting the resource type, click "Start Debugging" to view the template details and begin debugging. If the example template does not meet your requirements, click "Edit Mode" in the upper-right corner, edit the content, save, and start debugging. |
Terraform online execution
After writing a configuration file, the Terraform workflow proceeds through initialization, preview, and execution. Terraform Explorer runs these steps as debugging tasks, completing each action in sequence.
|
Feature set |
Feature point |
Feature description |
|
Executing configuration files |
Online initialization |
Initialization runs automatically as part of preview and execution. |
|
Online preview |
Click Preview. Terraform Explorer creates a new debugging task or runs |
|
|
Online execution |
Click Execute to run Click Preview and Execute to run |
|
|
Resource destruction |
Click Destroy Resources. Terraform Explorer generates a destruction plan with |
Benefits
Terraform Explorer provides the core Terraform functionality online, with no local installation, no manual coding, and no state management overhead.
No environment installation required
Terraform Explorer hosts the Terraform client online and accelerates Alibaba Cloud Provider downloads. No local Terraform installation or configuration is needed.
No code writing required
Terraform Explorer auto-generates configuration files through forms for individual resources. Each resource type also includes example templates that you can run with one click.
Templates and parameters from each execution are saved automatically. When you start a new debugging task, you can load content from previous runs.
No state management required
Terraform Explorer manages both local and remote state, using local state by default. It hosts the state for each execution so the same configuration file can run multiple times while preserving Terraform's native state management mechanism and ensuring state security.
Terms
|
Concept |
Description |
|
Version |
The Alibaba Cloud Terraform Provider version. The minimum supported version is 1.202.0. |
|
Product |
Cloud products supported by each Provider version. Supports fuzzy search by keywords. |
|
Resource type |
Resource types available for the selected cloud product in each Provider version. Supports fuzzy search by keywords. |
|
Template |
A Terraform configuration file in HCL format with UTF-8 encoding. Generate one by filling in form parameters, or use an example template for a resource type. |
|
Template version |
The template used for each debugging task execution is saved as a version. You can view details of each version. |
|
Task |
Created each time you click "Start Debugging". Each task has a unique state file and supports only one preview or execution at a time. |
|
Debugging record |
Generated for each run (preview or preview and execute) of a task. Each new record builds on the previous one. |
|
Debugging history |
Records all debugging tasks for each resource type. You can select a historical task and resume from its latest record. |
Access control
Some Terraform Explorer operations require authorization, including creating debugging tasks, previewing, executing, destroying resources, viewing debugging history, and viewing resource details. The following table lists the APIs that require authentication and their related features:
|
API name |
API description |
Related feature points (buttons) |
|
CreateExplorerModule |
Save template content |
Preview, Preview and Execute |
|
GetExplorerModule |
Get template content |
View template |
|
CreateExplorerModuleVersion |
Each time you continue debugging, the template content is saved as a new version |
Preview, Preview and Execute, Continue Debugging |
|
ListExplorerModules |
List templates |
Display example templates |
|
UpdateExplorerModuleAttribute |
Update template content |
Edit example templates |
|
DeleteExplorerModule |
Delete template |
Delete example templates |
|
CreateExplorerTask |
Create debugging task |
Preview, Preview and Execute |
|
GetExplorerTask |
Get debugging task details |
Debugging results |
|
DeleteExplorerTask |
Delete debugging task |
Delete task |
|
UpdateExplorerTaskAttribute |
Update debugging task |
Destroy resources |
|
CreateJob |
Create job, run debugging task |
Preview, Preview and Execute, Destroy resources |
|
GetJob |
Get debugging task execution details |
Debugging results |
|
OperateJob |
Operate job, execute debugging task after preview |
Preview and Execute, Execute, Destroy resources |
|
ListJobs |
Get job list—execution records of debugging tasks |
Debugging records |
|
CreateExplorerHistory |
Record each debugging task |
Debugging history |
|
ListExplorerHistories |
Get debugging history details and historical parameters |
Debugging history, Use historical parameters |
|
ListResources |
Get list and details of successfully created resources |
Resource details |
|
ExportTerraformCode |
Export Terraform code for the selected resources |
Online experience |
You can implement fine-grained access control through the APIs listed above, or use the following policy for quick authorization:
{
"Version": "1",
"Statement": [
{
"Effect": "Allow",
"Action": [
"iacservice:CreateExplorerModuleVersion",
"iacservice:GetExplorerModule",
"iacservice:CreateExplorerModule",
"iacservice:ListExplorerModules",
"iacservice:UpdateExplorerModuleAttribute",
"iacservice:DeleteExplorerModule"
],
"Resource": "acs:iacservice:*:*:explorermodule/*"
},
{
"Effect": "Allow",
"Action": [
"iacservice:CreateExplorerTask",
"iacservice:UpdateExplorerTaskAttribute",
"iacservice:GetExplorerTask",
"iacservice:DeleteExplorerTask"
],
"Resource": "acs:iacservice:*:*:explorertask/*"
},
{
"Effect": "Allow",
"Action": [
"iacservice:CreateJob",
"iacservice:GetJob",
"iacservice:listJobs",
"iacservice:OperateJob"
],
"Resource": "acs:iacservice:*:*:explorertask/*/job/*"
},
{
"Effect": "Allow",
"Action": [
"iacservice:ListResources",
"iacservice:ListExplorerHistories",
"iacservice:CreateExplorerHistory",
"iacservice:ExportTerraformCode",
"iacservice:ListRecentCalls"
],
"Resource": "*"
}
]
}