infrastructure-as-code
Infrastructure as Code
Managing infrastructure through code; version controlled, auditable, reproducible.
Context
You are writing infrastructure as code. Treat it like software; test, review, version.
Domain Context
- Declarative: Describe desired state; tool figures out changes
- Version Control: Infrastructure changes tracked like code
- Review: Infrastructure changes go through pull requests
- Reproducible: Same code → same infrastructure
- Idempotent: Running twice is same as running once
Instructions
- Use IaC: Terraform, CloudFormation, Pulumi; pick one
- Version Control: Commit infrastructure code
- Code Review: Pull requests for all changes
- Modules: Reusable components; DRY principle
- Secrets: Never commit secrets; use secrets manager
- State: Manage state file carefully; backup, lock
- Testing: Test infrastructure like code
Anti-Patterns
- Manual changes outside IaC; infrastructure drifts
- Secrets in code; instant compromise
- Massive monolithic infrastructure files; hard to review
- No version control; can't audit changes, can't rollback
- Testing infrastructure only in prod; catch errors early
Further Reading
- Terraform documentation
- AWS CloudFormation best practices
- IaC best practices (O'Reilly)
More from sethdford/claude-skills
api-test-automation
Expert approach to api-test-automation in test automation. Use when working with .
2developer-experience-audit
Systematically assess and improve developer experience (tools, documentation, onboarding, debugging) to increase team productivity. Use in roadmapping or when noticing developer friction.
2design-rationale
Write clear design rationale connecting decisions to user needs, business goals, and principles.
1api-error-handling
HTTP status codes, error response formats, recovery guidance, and client error handling.
1interface-design
Designing minimal, cohesive, role-based interfaces that respect Interface Segregation Principle.
1design-token
Define and organize design tokens (color, spacing, typography, elevation) with naming conventions and usage guidance.
1