Skip to content

Terraform module to manage the following Terraform Cloud/Enterprise resource (tfe_workspace)

License

Notifications You must be signed in to change notification settings

dhoppeIT/terraform-tfe-workspace

Repository files navigation

terraform-tfe-workspace

Terraform module to manage the following Terraform Cloud/Enterprise resource:

  • tfe_workspace

Graph

Graph

Usage

Copy and paste into your Terraform configuration, insert the variables and run terraform init:

module "tfe_organization" {
  source  = "dhoppeIT/organization/tfe"
  version = "~> 0.3"

  name  = "dhoppeIT"
  email = "[email protected]"
}

module "tfe_workspace" {
  source  = "dhoppeIT/workspace/tfe"
  version = "~> 0.2"

  name         = "terraform"
  organization = module.tfe_organization.name
}

Requirements

Name Version
terraform >= 1.0
tfe ~> 0.26

Providers

Name Version
tfe 0.39.0

Modules

No modules.

Resources

Name Type
tfe_workspace.default resource

Inputs

Name Description Type Default Required
agent_pool_id The ID of an agent pool to assign to the workspace string null no
allow_destroy_plan Whether destroy plans can be queued on the workspace bool true no
auto_apply Whether to automatically apply changes when a Terraform plan is successful bool false no
branch The repository branch that Terraform will execute from string null no
description A description for the workspace string null no
execution_mode Which execution mode to use string "remote" no
file_triggers_enabled Whether to filter runs based on the changed files in a VCS push bool true no
global_remote_state Whether the workspace allows all workspaces in the organization to access its state data during runs bool false no
identifier A reference to your VCS repository in the format / string null no
ingress_submodules Whether submodules should be fetched when cloning the VCS repository bool false no
name Name of the workspace string n/a yes
oauth_token_id The VCS Connection (OAuth Connection + Token) to use string null no
organization Name of the organization string n/a yes
queue_all_runs Whether the workspace should start automatically performing runs immediately after its creation bool true no
remote_state_consumer_ids The set of workspace IDs set as explicit remote state consumers for the given workspace list(string) [] no
speculative_enabled Whether this workspace allows speculative plans bool true no
ssh_key_id The ID of an SSH key to assign to the workspace string null no
structured_run_output_enabled Whether this workspace should show output from Terraform runs using the enhanced UI when available bool true no
tag_names A list of tag names for this workspace list(string) [] no
terraform_version The version of Terraform to use for this workspace string null no
trigger_prefixes List of repository-root-relative paths which describe all locations to be tracked for changes list(string) [] no
working_directory A relative path that Terraform will execute within string null no

Outputs

Name Description
id The workspace ID

Authors

Created and maintained by Dennis Hoppe.

License

Apache 2 licensed. See LICENSE for full details.