Last Updated: November 21, 2025
Pulumi
Infrastructure as Code with programming languages
Supported Languages
| Item | Description |
|---|---|
TypeScript/JavaScript
|
Most popular |
Python
|
Data science friendly |
Go
|
Performance |
C#
|
.NET integration |
Java
|
Enterprise |
YAML
|
Declarative option |
TypeScript Example
import * as aws from "@pulumi/aws";
import * as pulumi from "@pulumi/pulumi";
// Create an S3 bucket
const bucket = new aws.s3.Bucket("my-bucket", {
website: {
indexDocument: "index.html",
},
});
// Create an EC2 instance
const instance = new aws.ec2.Instance("web-server", {
instanceType: "t2.micro",
ami: "ami-0c55b159cbfafe1f0",
});
// Export outputs
export const bucketName = bucket.id;
export const instanceIp = instance.publicIp;
Common Commands
pulumi new aws-typescript
Create new project
pulumi up
Deploy infrastructure
pulumi preview
Preview changes
pulumi destroy
Destroy infrastructure
pulumi stack output
View outputs
pulumi config set key value
Set configuration
Best Practices
- Use real programming languages for logic
- Organize code with components
- Use stacks for different environments
- Store secrets in Pulumi config
💡 Pro Tips
Quick Reference
Pulumi uses real programming languages, not DSLs