aws

AWS Lambda serverless functions with Terraform

Deploy serverless functions on AWS Lambda using Terraform. Configure API Gateway integration, CloudWatch logging, environment variables, and IAM roles. Package Python or Node.js handlers with dependencies, set up event triggers, and manage function ve

Presigned S3 upload URLs (AWS SDK v2)

When clients upload files directly to S3, your API avoids handling large payloads and you get better scalability. I generate a presigned PUT URL with a short expiry and a constrained object key prefix so users can’t overwrite arbitrary objects. The cr

Terraform AWS RDS and ElastiCache provisioning

Terraform provisions managed database services declaratively. AWS RDS supports PostgreSQL, MySQL, and other engines with aws_db_instance. The engine_version pins database versions. instance_class sets compute size. allocated_storage and max_allocated_

AWS VPC and networking with Terraform

Build production-ready AWS VPC infrastructure using Terraform. Create public and private subnets across availability zones, configure NAT gateways, internet gateways, and route tables. Implement network ACLs and VPC flow logs for security and observab

AWS S3 and CloudFront for static asset hosting

AWS S3 stores static assets with high durability and availability. Bucket policies control access with JSON policy documents. CloudFront CDN distributes assets globally with edge caching. Origin Access Control (OAC) restricts S3 access to CloudFront o

Pre-signed S3 upload from the browser

Large file uploads don’t belong on app servers. My default is: the server issues a short-lived pre-signed URL, the browser uploads directly to S3, then the server stores the object key. That keeps latency low and costs predictable. Before signing, I v

AWS IAM policies and security best practices

AWS IAM (Identity and Access Management) controls access to cloud resources. Policies are JSON documents with Effect, Action, and Resource fields. The principle of least privilege grants only required permissions. Allow permits actions, Deny always ov