Terraform by HashiCorp, an AWS Partner Network (APN) Advanced Technology Partner and an individual from the AWS DevOps Competency is an "infrastructure as code" apparatus like AWS CloudFormation that permits you to make, update, and form your Amazon Web Services (AWS) infrastructure.
To know about Terraform in detail, check out this link.
In this article, we will be learning some of the most useful and commonly use Terraform Commands.
Terraform Command
|
Purpose
|
apply
|
To
Builds or changes infrastructure
|
console
|
To
get the Interactive console for Terraform interpolations
|
destroy
|
To
Destroy Terraform-managed infrastructure
|
env
|
For
envirnoment management
|
fmt
|
To
Rewrites config files to canonical format
|
get
|
To
Download and install modules for the configuration
|
graph
|
To
Create a visual graph of Terraform resources
|
import
|
To
Import existing infrastructure into Terraform
|
init
|
To
Initialize a Terraform working directory
|
output
|
To
Read output from a state file
|
plan
|
To
Generate and show an execution plan
|
providers
|
To
Prints a tree of the providers used in the configuration
|
refresh
|
To
Update local state file against real resources
|
show
|
To
Inspect Terraform state or plan
|
taint
|
To
Manually mark a resource for recreation
|
untaint
|
To
Manually unmark a resource as tainted
|
validate
|
To
Validates the Terraform files
|
version
|
To
Prints the Terraform version
|
workspace
|
For
Workspace management
|