1. 程式人生 > 實用技巧 >terraform init 報錯超時

terraform init 報錯超時

報錯資訊

通過此連結下載相關外掛
https://releases.hashicorp.com/terraform-provider-aws/2.70.0/
根據相應的系統選擇外掛

解壓下載的外掛

初始化外掛

➜  aws terraform init -plugin-dir=/opt/terraform/plugins

Initializing the backend...

Initializing provider plugins...

The following providers do not have any version constraints in configuration,
so the latest version was installed.

To prevent automatic upgrades to new major versions that may contain breaking
changes, it is recommended to add version = "..." constraints to the
corresponding provider blocks in configuration, with the constraint strings
suggested below.

* provider.aws: version = "~> 2.70"

Terraform has been successfully initialized!

You may now begin working with Terraform. Try running "terraform plan" to see
any changes that are required for your infrastructure. All Terraform commands
should now work.

If you ever set or change modules or backend configuration for Terraform,
rerun this command to reinitialize your working directory. If you forget, other
commands will detect it and remind you to do so if necessary.