iac
|
Works with
--- name: iac description: | license: MIT --- # Infrastructure as Code ## Overview Infrastructure as Code (IaC) defines and manages cloud resources, containers, and deployment pipelines through declarative or imperative code rather than manual configuration. This skill covers the major IaC tools and their trade-offs. ## Tool Landscape | Tool | Approach | Language | Scope | |------|----------|----------|-------| | **Terraform** | Declarative | HCL | Multi-cloud infrastructure | | **Pulumi** | Imperative | TypeScript, Python, Go, C# | Multi-cloud infrastructure | | **CloudFormation** | Declarative | JSON/YAML | AWS-only infrastructure | | **Bicep** | Declarative | Bicep DSL | Azure-only infrastructure | | **ARM** | Declarative | JSON | Azure-only infrastructure | | **Kubernetes** | Declarative | YAML | Container orchestration | | **Helm** | Declarative (templated) | YAML + Go templates | Kubernetes package management | | **Docker** | Declarative | Dockerfile | Container image builds | | **Crossplane** | Declarative | YAML (K8s CRDs) | Kubernetes-native cloud provisioning | | **Dagger** | Imperative | TypeScript, Python, Go | CI/CD pipelines as code | ## Choosing the Right Tool ### Cloud Infrastructure - **Multi-cloud or cloud-agnostic?** Use Terraform or Pulumi - **AWS-only?** CloudFormation is native, or use Terraform/Pulumi - **Azure-only?** Bicep is the modern choice (replaces ARM templates) - **Kubernetes-native approach?** Crossplane extends the K8s control plane to cloud resources ### Containers and Orchestration - **Building images?** Dockerfile with multi-stage builds - **Running containers?** Kubernetes manifests or Docker Compose - **Packaging K8s apps?** Helm charts for templated, distributable deployments ### Pipelines - **Programmable CI/CD?** Dagger runs pipelines in containers with real language SDKs ## General Best Practices - Store all IaC in version control alongside application code. - Use state management (Terraform state, Pulumi state, CloudFormation stacks) to track what's deployed. - Pin provider/module versions for reproducible deployments. - Use environments (dev/staging/prod) with parameterized configurations. - Validate changes before applying: `terraform plan`, `pulumi preview`, CloudFormation change sets. - Use secrets management — never hardcode credentials in IaC files.
More DevOps & Infrastructure skills
azure-ai
microsoft/azure-skills
Use for Azure AI: Search, Speech, OpenAI, Document Intelligence. Helps with search, vector/hybrid search, speech-to-text, text-to-speech, transcription, OCR. WHEN: AI Search, query search, vector search, hybrid search, semantic search, speech-to-text, text-to-speech, transcribe, OCR, convert text to speech.
appinsights-instrumentation
microsoft/azure-skills
Guidance for instrumenting webapps with Azure Application Insights. Provides telemetry patterns, SDK setup, and configuration references. WHEN: how to instrument app, App Insights SDK, telemetry patterns, what is App Insights, Application Insights guidance, instrumentation examples, APM best practices.
azure-storage
microsoft/azure-skills
Azure Storage Services including Blob Storage, File Shares, Queue Storage, Table Storage, and Data Lake. Answers questions about storage access tiers (hot, cool, cold, archive), when to use each tier, and tier comparison. Provides object storage, SMB file shares, async messaging, NoSQL key-value, and big data analytics. Includes lifecycle management. USE FOR: blob storage, file shares, queue storage, table storage, data lake, upload files, download blobs, storage accounts, access tiers, storage tiers, hot cool cold archive, storage tier comparison, when to use storage tiers, lifecycle management, Azure Storage concepts. DO NOT USE FOR: SQL databases, Cosmos DB (use azure-prepare), messaging with Event Hubs or Service Bus (use azure-messaging).

