本文为您介绍在使用Terraform过程中常用的一些命令,执行terraform
命令可以查看完整的命令列表,执行terraform -h
或terraform --help
命令可以获取完整的用法。如下文所示:
$ terraform Usage: terraform [-version] [-help] <command> [args] The available commands for execution are listed below. The most common, useful commands are shown first, followed by less common or more advanced commands. If you're just getting started with Terraform, stick with the common commands. For the other commands, please read the help and docs before usage. ... $ terraform init -h Usage: terraform init [options] [DIR] Initialize a new or existing Terraform working directory by creating initial files, loading any remote state, downloading modules, etc. This is the first command that should be run for any new or existing Terraform configuration per machine. This sets up all the local data necessary to run Terraform that is typically not committed to version control. ...