AWS Terraform Resources
Cost estimation reference for 35 AWS resources supported by C3X. Each page covers pricing dimensions, Terraform examples, and optimization tips.
Compute
Containers
aws_ecr_repositoryA container image registry. Priced per GB-month stored, with the first 500 MB free, plus data transfer charges.
aws_ecs_clusterAn ECS cluster. The cluster itself is free. Cost comes from the EC2 instances and Fargate tasks that run inside it.
aws_ecs_serviceA long-running ECS service. Cost depends on launch type: EC2 (pay for nodes), Fargate (pay per task vCPU/memory), or Fargate Spot.
aws_eks_clusterA managed Kubernetes control plane. Flat $0.10/hour per cluster, with worker nodes and storage billed separately.
Database
aws_db_instanceA managed relational database instance on RDS. Priced per hour by instance class, engine, deployment option, and region, with storage and IOPS billed separately.
aws_dynamodb_tableA managed NoSQL table. Pay-per-request (on-demand) or provisioned capacity, plus storage. No instances to manage.
aws_elasticache_clusterManaged Redis or Memcached. Priced per node-hour by instance type, with no storage or request charges.
aws_glue_jobA managed ETL job using Spark or Python shell. Priced per DPU-hour with 1-minute billing minimum, plus development endpoint and Data Catalog costs.
aws_opensearch_domainA managed OpenSearch (formerly Elasticsearch) cluster. Priced per node-hour by instance type, plus storage and optional UltraWarm/Cold tiers.
aws_rds_clusterAn Aurora cluster (MySQL or PostgreSQL compatible). Priced by per-instance compute, storage by GB used, and I/O (Standard) or compute (I/O-Optimized).
aws_redshift_clusterA managed data warehouse. Two compute models: classic node-based pricing (per-hour) or Redshift Serverless (per-RPU-hour), plus managed storage.
Messaging
aws_kinesis_streamA real-time data stream. Two capacity modes: Provisioned (priced per shard-hour) or On-Demand (priced per record and per GB).
aws_msk_clusterA managed Apache Kafka cluster. Priced per broker-hour by instance type, plus EBS storage per GB-month and data transfer.
aws_sns_topicA pub/sub topic for sending notifications. Priced per message published, per delivery, and by destination protocol.
aws_sqs_queueA managed message queue. Priced per request, with no per-queue or storage fee. Generous free tier.
Networking
aws_api_gateway_rest_apiA REST API endpoint. Priced per request, with no base hourly fee. Cheaper than ALB at low volume.
aws_cloudfront_distributionA CDN distribution. Priced by data transfer to viewers and request count, with rates varying by region.
aws_dx_connectionA dedicated physical network connection from on-premises to AWS. Priced per port-hour by bandwidth, plus per-GB data transfer at a lower rate than internet.
aws_ec2_transit_gatewayA network hub connecting multiple VPCs, VPNs, and Direct Connects. $0.05/hour per attachment plus $0.02/GB processed.
aws_eipA static public IPv4 address. Free while attached and in use, $0.005/hour while detached or unassociated. As of 2024, also charges per-hour for attached IPv4 in some scenarios.
aws_lbA managed load balancer (ALB or NLB). Priced per hour plus per LCU/NLCU based on processed traffic.
aws_nat_gatewayA managed NAT gateway for outbound internet access from private subnets. Notoriously expensive: $0.045/hour plus $0.045/GB processed.
aws_route53_zoneA DNS hosted zone. Flat $0.50/month per zone, plus tiered per-query charges.
aws_vpc_endpointA private endpoint into AWS services from your VPC. Gateway endpoints (S3, DynamoDB) are free; Interface endpoints are ~$7/month per AZ plus data fees.
aws_vpn_connectionA site-to-site IPsec VPN connection between your VPC and on-premises network. $0.05/hour per active connection plus data transfer.
Observability
aws_cloudtrailAn audit log of AWS API calls. Management events are free. Data events and Insights are billed per event.
aws_cloudwatch_log_groupA log group for storing application and AWS service logs. Priced by ingestion ($0.50/GB), storage ($0.03/GB-month), and queries.
Security
aws_kms_keyA managed encryption key. Flat $1/month per key, plus per-request charges for cryptographic operations.
aws_secretsmanager_secretA managed secret with versioning, rotation, and IAM-controlled access. Flat $0.40/month per secret plus per-API-call charges.
aws_wafv2_web_aclA web application firewall. $5/month per Web ACL, $1/month per rule, plus $0.60 per million inspected requests.
Serverless
Storage
aws_ebs_volumeA persistent block storage volume. Priced per GB-month by volume type, with separate IOPS and throughput charges on certain types.
aws_efs_file_systemA managed NFS file system for shared access from EC2, ECS, EKS, and Lambda. Priced per GB stored, with tiered storage classes.
aws_s3_bucketObject storage on S3. Priced by storage class, request count, and data transfer, with the bucket itself being free.