Skip to main content
Reference architecture only. This page is not a production-certified deployment procedure and predates the current activation, image-pinning, secret-management, and network-isolation baseline. Use the supported on-premises guide or complete an enterprise architecture review before deployment.

Overview

This guide walks you through deploying CaseBender on AWS using pre-built Docker images with Amazon ECS (Elastic Container Service) and Fargate.

Prerequisites

  1. AWS Account
  2. AWS CLI installed and configured
  3. Docker installed

Step 1: Initial Setup

Install and Configure AWS CLI

Step 2: Set Up AWS Infrastructure

Create S3 Bucket for Storage

Create a VPC

Create Subnets

Set Up RDS (PostgreSQL)

Set Up ElastiCache (Redis)

Step 3: Create ECR Repositories

Step 4: Create ECS Cluster

Step 5: Create Task Definitions

Create task definition JSON files for each service:
Register the task definitions:

Step 6: Create Application Load Balancer

Step 7: Create ECS Services

Step 8: Set Up Route 53 (Optional)

If you’re using a custom domain:

Monitoring and Maintenance

Set Up CloudWatch Alarms

View Logs

Update Services

Cost Optimization

  1. Use Fargate Spot for non-critical workloads
  2. Implement auto-scaling based on metrics
  3. Choose appropriate instance sizes
  4. Use Reserved Instances for predictable workloads

Security Best Practices

  1. Use AWS Secrets Manager for sensitive data
  2. Implement WAF rules
  3. Enable VPC Flow Logs
  4. Regular security group audits
  5. Enable AWS GuardDuty

Next Steps

  • Set up CI/CD pipeline with AWS CodePipeline
  • Configure backup strategies
  • Implement monitoring and alerting
  • Review security best practices