IAC / A CONCEPT NOTE
Pulumi
infrastructure as code using real programming languages
Overview · mechanism
pitfall · examples
01 / THE SHORT VERSION
The idea in a few sentences.
Pulumi lets you define cloud infrastructure in TypeScript, Python, Go, or C# — not a DSL like HCL. You write a for loop to create 10 S3 buckets? Done. Import a library for string manipulation? Easy. Pulumi translates your code into cloud API calls and stores state just like Terraform.
02 / FOLLOW THE MECHANISM
How pulumi differs from terraform
You
write
new aws.s3.Bucket('my-bucket')in TypeScript, with full IDE autocompletion.Pulumi CLI
runs your code — constructs a dependency graph from your program execution.
State engine
compares the desired state (from your code) against the current state (from the backend).
Provider
calls AWS APIs to create, update, or delete resources — or previews the changes with
pulumi preview.
04 / COMMAND NOTES
Read the command, then the result.
Inspect the flags and arguments before trying an example. Snippets can need local setup, replacement values, or resources in your own environment.
scaffold a new Pulumi project
pulumi new aws-typescriptselect a stack and deploy
pulumi stack select dev && pulumi up05 / CHECK YOURSELF
Could you explain Pulumi to a teammate?
Try it out loud in two sentences: what it is, and the one detail that changes the picture. If you stall, the gap is the part to reread.
Up next in Infrastructure as codePackerbuilding golden machine images with code