Assignment-4

what is terraform

Terraform is a tool which is used to write a code for infrastructure and it allows to programmatically provision the physical resources an application requires to run. it works across all the cloud providers at the same time.Terraform’s direct competitors like cloudFormation,which work primarly with a single cloud provider only.This helps to manages the application infrastructure through programming.

One example terraform program

resource “github_repository” “Sample” {
name = “Proj1”
description = “My first project”

visibility = “public”
}

provider github

{token=”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”

owner=”Organization”

}

List of 5 terraform commands and its use

  1. terraform init – used to initialize the directory which consists of configuration files.
  2. terraform plan – checks the configuration to determine the desired state of all the resources it declares.
  3. terraform apply – carries out the planned changes to resource using the same type of infrastructure providers API.
  4. terraform destroy – destroys all the resources being managed by current directory.
  5. terraform show – provides an output of plan file in understandable manner.
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x