Back to articles
Pulumi Has Free Infrastructure as Code in Any Language — Here's Why Developers Love It
How-ToDevOps

Pulumi Has Free Infrastructure as Code in Any Language — Here's Why Developers Love It

via Dev.to DevOpsAlex Spinov

Terraform uses HCL. AWS CDK is verbose. Pulumi lets you write infrastructure in TypeScript, Python, Go, or C# — languages you already know. Quick Start curl -fsSL https://get.pulumi.com | sh pulumi new aws-typescript Your First Infrastructure import * as pulumi from " @pulumi/pulumi " ; import * as aws from " @pulumi/aws " ; // Create an S3 bucket const bucket = new aws . s3 . Bucket ( " my-bucket " , { website : { indexDocument : " index.html " , }, }); // Upload a file const indexHtml = new aws . s3 . BucketObject ( " index " , { bucket : bucket . id , content : " <h1>Hello from Pulumi!</h1> " , contentType : " text/html " , }); // Export the URL export const url = pulumi . interpolate `http:// ${ bucket . websiteEndpoint } ` ; pulumi up # Preview and deploy Real-World: Full-Stack on AWS import * as aws from " @pulumi/aws " ; import * as awsx from " @pulumi/awsx " ; // VPC with best practices const vpc = new awsx . ec2 . Vpc ( " app-vpc " , { natGateways : { strategy : " Single " } }

Continue reading on Dev.to DevOps

Opens in a new tab

Read Full Article
7 views

Related Articles