一键导入
terraform-patterns
Apply Terraform module structure, state management, and variable patterns for infrastructure as code. Use when writing Terraform.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Apply Terraform module structure, state management, and variable patterns for infrastructure as code. Use when writing Terraform.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Manage GitHub Projects v2 board: add issues, update field values, and query board state. Use when managing project boards.
Run WCAG 2.2 Level AA accessibility audits against generated UI. Use when a story has ui:true or when asked to audit accessibility.
Generate a complete component file tree wired to design tokens with tests and Gherkin spec. Use when scaffolding a new UI component.
Extract Gherkin scenarios from story markdown files into runnable .feature files and generate step definition stubs. Use when syncing stories to test suites.
Read and write design tokens in W3C DTCG format (tokens.json) and emit CSS, Tailwind, and Mantine outputs. Use when modifying or generating design tokens.
Apply Docker and Docker Compose best practices for containerising services. Use when writing or reviewing Dockerfiles and compose configs.
| name | terraform-patterns |
| description | Apply Terraform module structure, state management, and variable patterns for infrastructure as code. Use when writing Terraform. |
infra/terraform/
├── modules/
│ ├── networking/
│ ├── database/
│ └── compute/
└── environments/
├── dev/
│ ├── main.tf
│ ├── variables.tf
│ └── terraform.tfvars
├── staging/
└── prod/
# modules/database/main.tf
resource "aws_db_instance" "main" {
# finops: ~$180/mo (db.t3.medium, 100GB gp3, single AZ)
identifier = "${var.environment}-${var.name}-db"
engine = "postgres"
engine_version = "16"
instance_class = var.instance_class
allocated_storage = var.storage_gb
storage_type = "gp3"
storage_encrypted = true
username = var.username
password = var.password
vpc_security_group_ids = [aws_security_group.db.id]
db_subnet_group_name = aws_db_subnet_group.main.name
backup_retention_period = var.environment == "prod" ? 7 : 1
deletion_protection = var.environment == "prod"
tags = merge(var.tags, {
Environment = var.environment
ManagedBy = "terraform"
})
}
# Initialize (first time or after provider changes)
terraform init
# Format check (CI)
terraform fmt -check -recursive
# Validate syntax
terraform validate
# Plan (always before apply)
terraform plan -out=plan.tfplan -var-file=environments/dev/terraform.tfvars
# Apply (requires explicit instruction)
terraform apply plan.tfplan
# State inspection
terraform show
terraform state list
terraform validate before reporting complete.terraform plan to show what will change.terraform apply without explicit instruction.# finops: cost estimate.