This module is stand alone and intended to be executed with the terraform client to bootstrap the vmp workspace to manage all other resources for a organization.
The modules pre-requisites are outlined in the main project README.md
- We suggest you review the code in this folder.
- update
terraform.auto.tfvars.example
with your values - For ease of use rename to
terraform.auto.tfvars.example
toterraform.auto.tfvars
Note: the *.tfvars
are excluded by way of .gitignore from version control.
terraform init
run terraform plan and review the intended plan correct any errors
# now run the following
terraform plan -out=vmp-bootstrap.tfplan
terraform apply "vmp-bootstrap.tfplan"
# review the outputs
terraform state list
terraform output
# navigate to the vmp_bootstrap_workspace_url in your browser
terraform output vmp_bootstap_workspace_url
"https://app.terraform.io/app/example/workspaces/vm_workspace"
You will see the resources as documented below are created and you can review these in the tfe provider https://registry.terraform.io/providers/hashicorp/tfe/latest documentation.
To destroy the resources created by the bootstrap root module. First ensure you have destroyed or are at least aware of the resources being created by the resource tfe_workspace.this
.
# tfe_workspace.this will be created
+ resource "tfe_workspace" "this" {
...
+ name = "vmp_workspace"
+ operations = (known after apply)
+ organization = (known after apply)
... #truncated
To destroy the resources created see the destroy and destruction section of the root module README.md
To destroy
or taint
individual resources (used to refresh tokens for example) see https://developer.hashicorp.com/terraform/cli/commands/taint
Name | Version |
---|---|
tfe | 0.38.0 |
Name | Version |
---|---|
tfe | 0.38.0 |
No modules.
Name | Type |
---|---|
tfe_organization_token.this | resource |
tfe_team.this | resource |
tfe_team_access.this | resource |
tfe_team_token.this | resource |
tfe_variable.oauth_name | resource |
tfe_variable.tfe_token | resource |
tfe_variable.tfx_org_token | resource |
tfe_variable_set.this | resource |
tfe_workspace.this | resource |
tfe_workspace_variable_set.this | resource |
tfe_oauth_client.this | data source |
Name | Description | Type | Default | Required |
---|---|---|---|---|
branch | (Optional String) Branch to deploy VCS source. | string |
"main" |
no |
oauth_name | (Required String) Name of OAuth VCS connection you created | string |
n/a | yes |
organization | (Required String) Organization name | string |
n/a | yes |
terraform_server | (Optional String) defaults to app.terraform.io, but otherwise the FQDN of your TFE server | string |
"app.terraform.io" |
no |
vcs_repo_identifier | (Required String) username/projectname of the VCS project or repository | string |
n/a | yes |
Name | Description |
---|---|
vmp_bootstap_workspace_url | n/a |