百科.dev
全部条目在线工具AI 编程趋势榜开源项目技术资讯提交条目
登录
< 返回工具列表
T

terraform-provider

> 编程语言
开源

[已弃用] 此仓库已被弃用,请访问 https://GitHub.com/terraform-providers/terraform-provider-alicloud

381 stars0 点赞1 次浏览
访问官网GitHub

工具介绍

[已弃用] 此仓库已被弃用,请访问 https://GitHub.com/terraform-providers/terraform-provider-alicloud

[NOTES]: This repo has been deprecated and please refer to the latest repo: https://github.com/aliyun/terraform-provider-alicloud

Alicloud (Alibaba Cloud) Terraform provider

This is the official repository of the Alicloud Terraform provider. It currently supports Terraform version ≥ v0.8.2.

If you are not planning to contribute to this repo, you can download the compiled binaries from https://github.com/alibaba/terraform-provider/releases and move the binaries (bin/terraform-provider-alicloud) into the folder under the Terraform PATH such as /usr/local/terraform.

Alternatively, the provider can be installed as described in the developer notes.
This way you will be able to sync the repo as active development is going on.

-> Note: When you use Terraform on a Windows computer, please install golang first, otherwise you might get this issue (the bug appeared in the version 1.8.1 and was fixed in the version 1.11.0).

Example

Example modules can be found in the terraform/examples directory.

Developer notes

Setting up

  • Install Terraform: https://www.terraform.io/intro/getting-started/install.html
  • Install golang: https://golang.org/doc/install
  • Install goimports: https://godoc.org/golang.org/x/tools/cmd/goimports
    go get golang.org/x/tools/cmd/goimports
  • Finally:
…

Regions

cn-qingdao
cn-beijing
cn-zhangjiakou
cn-huhehaote
cn-hangzhou
cn-shanghai
cn-shenzhen
cn-hongkong

ap-northeast-1
ap-southeast-1
ap-southeast-2
ap-southeast-3
ap-southeast-5
ap-south-1

us-east-1
us-west-1

me-east-1

eu-central-1

For more information about the regions and availability zones, please use the data sources alicloud_regions and alicloud_zones.

Supported products

  • ECS
  • Block Storage
  • SLB
  • VPC
  • NAT Gateway
  • RDS
  • ESS
  • OSS
  • RAM
  • CDN
  • DNS
  • Container Service
  • Log Service
  • Function Compute
  • TableStore

Documents

The most recent documentation is available here:

  • Terraform Docs
  • Github

Acceptance Testing

Before making a release, the resources and data sources are tested automatically with acceptance tests (the tests are located in the alicloud/*_test.go files). You can run them by entering the following instructions in a terminal:

bash
cd $GOPATH/src/github.com/alibaba/terraform-provider
export ALICLOUD_ACCESS_KEY=xxx
export ALICLOUD_SECRET_KEY=xxx
export ALICLOUD_REGION=xxx
export ALICLOUD_ACCOUNT_ID=xxx
export outfile=gotest.out
TF_ACC=1 TF_LOG=INFO go test ./alicloud -v -run=TestAccAlicloud -timeout=1440m | tee $outfile
go2xunit -input $outfile -output $GOPATH/tests.xml

-> Note: The last line is optional, it allows to convert test results into a XML format compatible with xUnit.

Because some features are not available in all regions, the following environment variables can be set in order to skip tests that use these features:

  • ALICLOUD_SKIP_TESTS_FOR_SLB_SPECIFICATION=true - Server Load Balancer with guaranteed performance specifications (old implementation has only shared performance)
  • ALICLOUD_SKIP_TESTS_FOR_SLB_PAY_BY_BANDWIDTH=true - Server Load Balancer with a "pay by bandwidth" billing method (mostly available in China)
  • ALICLOUD_SKIP_TESTS_FOR_FUNCTION_COMPUTE=true - Function Compute
  • ALICLOUD_SKIP_TESTS_FOR_PVTZ_ZONE=true - Private Zone
  • ALICLOUD_SKIP_TESTS_FOR_RDS_MULTIAZ=true - Apsara RDS with multiple availability zones
  • ALICLOUD_SKIP_TESTS_FOR_CLASSIC_NETWORK=true - Classic network configuration

Common problems

bash
Error configuring: 1 error(s) occurred:
* Incompatible API version with plugin. Plugin version: 2, Ours: 1

# fix by manually setting the branch in the sources
cd src/github.com/hashicorp/terraform/
git checkout v
cd -

# rebuild
sudo -E "PATH=$PATH" make all

How to contribute

  • If you are not sure or have any doubt, feel free to ask and/or submit an issue or PR. We appreciate all contributions and try to make the process as smooth as possible.
  • Contributions are welcome and will be merged via PRs.

Contributors

  • demonwy
  • heww([email protected])
  • ShuWei
  • WangYuelucky([email protected])
  • GuiMin([email protected])

License

  • This project is licensed under the Apache License, Version 2.0. See LICENSE for the full license text.

Reference

  • Terraform Document: https://www.terraform.io/intro/
  • Terraform Registry Of Alicloud: https://registry.terraform.io/modules/alibaba
  • Terraform Alicloud Examples: Official Examples , Other Examples

Issues· 0 开放

查看全部 Issues在 GitHub 打开

暂无开放 Issues,或尚未同步最近议题。

> 标签

Go

暂无评论,来聊聊你的看法吧

> 工具信息

发布日期2026年8月1日
最后更新2026年9月17日
分类编程语言
定价开源

> 相关工具

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言