github.com/kanishk98/terraform@v1.3.0-dev.0.20220917174235-661ca8088a6a/website/docs/language/settings/terraform-cloud.mdx (about)

     1  ---
     2  page_title: Terraform Cloud Configuration - Terraform Settings - Configuration Language
     3  description: >-
     4    The nested `cloud` block configures Terraform's integration with Terraform
     5    Cloud.
     6  ---
     7  
     8  # Terraform Cloud Configuration
     9  
    10  The main module of a Terraform configuration can integrate with Terraform Cloud to enable its [CLI-driven run workflow](/cloud-docs/run/cli). You only need to configure these settings when you want to use Terraform CLI to interact with Terraform Cloud. Terraform Cloud ignores them when interacting with
    11  Terraform through version control or the API.
    12  
    13  > **Hands On:** Try the [Migrate State to Terraform Cloud](https://learn.hashicorp.com/tutorials/terraform/cloud-migrate) tutorial.
    14  
    15  ## Usage Example
    16  
    17  To configure the Terraform Cloud CLI integration, add a nested `cloud` block within the `terraform` block. You cannot use the CLI integration and a [state backend](/language/settings/backends) in the same configuration.
    18  
    19  Refer to [Using Terraform Cloud](/cli/cloud) in the Terraform CLI documentation for full configuration details, migration instructions, and command line arguments.
    20  
    21  ```hcl
    22  terraform {
    23    cloud {
    24      organization = "example_corp"
    25      ## Required for Terraform Enterprise; Defaults to app.terraform.io for Terraform Cloud
    26      hostname = "app.terraform.io"
    27  
    28      workspaces {
    29        tags = ["app"]
    30      }
    31    }
    32  }
    33  ```
    34  
    35  
    36