Terraspace
The Terraform Framework.
Official Docs Site: terraspace.cloud
Quick Start
Here are commands to get started:
terraspace new project infra --plugin aws --examples
cd infra
terraspace up demo
terraspace down demo
- The
new
command generates a starter project. - The
up
command creates an s3 bucket. - The
down
command cleans up and deletes the bucket.
The default plugin is aws. Other plugins also supported are: google and azurerm.
Usage
Create infrastructure:
$ terraspace up demo -y
Building .terraspace-cache/dev/stacks/demo
Current directory: .terraspace-cache/dev/stacks/demo
=> terraform init -get > /dev/null
Built in .terraspace-cache/dev/stacks/demo
=> terraform apply -auto-approve
random_pet.bucket: Creating...
random_pet.bucket: Creation complete after 0s [id=amusing-mouse]
module.bucket.aws_s3_bucket.this: Creating...
module.bucket.aws_s3_bucket.this: Creation complete after 1s [id=bucket-amusing-mouse]
Apply complete! Resources: 2 added, 0 changed, 0 destroyed.
Outputs:
bucket_name = bucket-amusing-mouse
$
Destroy infrastructure:
$ terraspace down demo -y
Building .terraspace-cache/dev/stacks/demo
Current directory: .terraspace-cache/dev/stacks/demo
=> terraform init -get > /dev/null
Built in .terraspace-cache/dev/stacks/demo
=> terraform destroy -auto-approve
random_pet.bucket: Refreshing state... [id=amusing-mouse]
module.bucket.aws_s3_bucket.this: Refreshing state... [id=bucket-amusing-mouse]
module.bucket.aws_s3_bucket.this: Destroying... [id=bucket-amusing-mouse]
module.bucket.aws_s3_bucket.this: Destruction complete after 1s
random_pet.bucket: Destroying... [id=amusing-mouse]
random_pet.bucket: Destruction complete after 0s
Destroy complete! Resources: 2 destroyed.
$
Features
- Config Structure: A common config structure that gets materializes with the deployed module. Configs can be dynamically controlled to keep your code DRY. You can override the settings if needed, like for using existing backends. See: Existing Backends.
- Generators: Built-in generators to quickly create the starter module. Focus on code instead of boilerplate structure.
- Tfvars: Use the same code with different tfvars to create multiple environments. Terraspace conventionally loads tfvars from the
tfvars
folder. - Layering: Rich layering support. This allows you to build different environments like dev and prod with the same code.
- Testing: A testing framework that allows you to create test harnesses, deploy real-resources, and have higher confidence that your code works.
- Configurable CLI: Configurable CLI Hooks and CLI Args allow you to adjust the underlying terraform command.
For more info: terraspace.cloud