This directory contains comprehensive guides for using ThothCTL in real-world scenarios. Each use case demonstrates how ThothCTL enables modern infrastructure development workflows.
Complete AI-assisted IaC development workflow with Kiro CLI and MCP integration.
What youβll learn:
Key Features:
8-phase DevSecOps lifecycle for Infrastructure as Code projects.
What youβll learn:
Key Features:
Quick Start: DevSecOps Quick Start Guide
Organize projects with logical boundaries and multi-tenancy support.
What youβll learn:
Validate environments, IaC, costs, and change impact.
What youβll learn:
Track dependencies and versions with professional reports.
What youβll learn:
# Install all development tools
thothctl init env
# Creates: Terraform, Terragrunt, OpenTofu, Checkov, Trivy, Kiro CLI, etc.
# Create a space
thothctl init space --space-name lab-github
# Create project from template
thothctl init project --project-name my-infra --reuse --space lab-github
# Choose from official scaffolds:
# - terraform-scaffold
# - terragrunt-scaffold
# - tofu-scaffold
# - cdk-scaffold
# - cloudformation-scaffold
# Full pipeline (all phases)
thothctl workflow devsecops --phase all
# Pre-deployment gate (test + secure)
thothctl workflow devsecops --phase pre-deploy --enforcement hard
# Individual phases
thothctl workflow devsecops --phase plan # Cost + blast radius
thothctl workflow devsecops --phase develop # Environment + structure + docs
thothctl workflow devsecops --phase build # Inventory + versions
thothctl workflow devsecops --phase secure # Checkov + Trivy + OPA
thothctl workflow devsecops --phase monitor # Drift detection
# Or run individual commands directly:
thothctl check iac -type cost-analysis
thothctl scan iac -t checkov -t trivy
thothctl inventory iac --check-versions
# Start MCP server
thothctl mcp server
# In another terminal, use Kiro CLI
kiro-cli chat --agent thoth
# Example AI conversation:
# User: "Scan my Terraform code for security issues"
# AI: [Executes scan, analyzes results, suggests fixes]
thothctl init env - Bootstrap development environmentthothctl init space - Create logical spacethothctl init project - Create project from scaffoldthothctl check environment - Validate tool versionsthothctl check iac - Validate IaC configurationthothctl check iac -type cost-analysis - AWS cost estimationthothctl check iac -type blast-radius - Change impact assessmentthothctl scan iac - Security scanning with Checkov (default)thothctl scan iac -t checkov -t trivy -t opa - Multi-tool scanningthothctl scan iac --enforcement hard - Fail pipeline on violationsthothctl workflow devsecops --phase all - Full DevSecOps pipelinethothctl workflow devsecops --phase secure - Security scanning phasethothctl workflow devsecops --phase pre-deploy - Pre-deployment gate (test + secure)thothctl workflow devsecops --phase plan - Cost estimation + blast radiusthothctl workflow devsecops --enforcement hard - Block on violationsthothctl document iac - Generate documentationthothctl document iac --ai - AI-powered documentationthothctl inventory iac - Create inventorythothctl inventory iac --check-versions - Module version trackingthothctl inventory iac --check-provider-versions - Provider version trackingthothctl inventory iac --report-type cyclonedx - Generate CycloneDX SBOMthothctl project iac - Manage IaC projectsthothctl list projects - List all projectsthothctl remove project - Remove projectthothctl generate stacks - Generate infrastructure stacksthothctl generate components - Generate componentsthothctl mcp server - Start MCP server for AIthothctl upgrade - Self-update ThothCTLGitHub Actions:
- name: Security Scan
run: thothctl scan iac -t checkov -t trivy --enforcement hard --output sarif
- name: Cost Analysis
run: thothctl check iac -type cost-analysis
GitLab CI:
security_scan:
script:
- thothctl scan iac -t checkov -t trivy --enforcement hard
- thothctl check iac -type blast-radius
# .pre-commit-config.yaml
- repo: local
hooks:
- id: thothctl-scan
name: ThothCTL Security Scan
entry: thothctl scan iac -t checkov
language: system
# Start MCP server for AI assistant integration
thothctl mcp server
# Or use the AI review directly
thothctl ai-review analyze -d ./terraform -p ollama
organization/
βββ spaces/
β βββ dev/ # Development space
β βββ staging/ # Staging space
β βββ prod/ # Production space
βββ projects/
βββ networking/ # Shared networking
βββ compute/ # Compute resources
βββ data/ # Data infrastructure
project/
βββ terraform/ # Terraform IaC
βββ terragrunt/ # Terragrunt configs
βββ cloudformation/ # CloudFormation templates
βββ cdk/ # CDK code
thothctl <command> --helpAfter mastering these use cases, explore: