Terraform Cloud Integration

Overview

Compute Software integrates with Terraform Cloud to map the resources in your Terraform Workspace with the Compute Software platform.

Features

  • A new filter category will appear to allow you to filter by your Terraform Workspace name. The filter category is available in all “Optimizations” tabs.

    Terraform Cloud

  • All AWS resources the Compute Software platform supports that are managed by a Terraform Cloud Workspace will include a new section in the resource drawer under “Additional Information.” The section is titled “Terraform” and includes the Organization ID, Workspace the resource resides in, and a link to the Terraform Cloud console for the Workspace.

    Terraform Cloud

Set up

The Terraform Cloud integration interacts directly with the Terraform Cloud public API. The interaction requires a User API Token or Team API Token. Generally, a Team API Token should be preferred.

  1. Navigate to the Terraform Cloud console Teams page: Organization settings > Teams > (desired team). Ensure the team has access to “Manage Workspaces”.

    Terraform Cloud

  2. Follow Terraform’s documentation on creating a Team API token. After creating the token, copy the value for use in the Compute Software platform.

    Terraform Cloud

  3. Navigate to the Compute Software Terraform Cloud integration page and click “Add New Integration.

  4. In the modal, input an integration name and paste the Terraform Team API token previously created.

    Terraform Cloud

  5. Click “Add Integration”

Resource Syncing

After creating your first Terraform Cloud integration, the platform will begin syncing all managed resources across all Workspaces the the API token has access to. The sync occurs once per hour.

The sync process accesses provider resource information by ingesting the current Terraform state file for each Workspace and mapping it to Compute Software platform resources. The Terraform state file resides in process memory for a short period while the mapping is completed. Compute Software does not persist or store the state file in any way.

Permissions Used