LogstackLogstack

Cloud Deployment

Deploy LogStack to AWS, GCP, or DigitalOcean.

Cloud Deployment

Deploy LogStack to major cloud platforms with managed databases.

Architecture

For production deployments, we recommend:

  • Managed PostgreSQL — RDS, Cloud SQL, or Managed Databases
  • Managed Redis — ElastiCache, Memorystore, or Managed Redis
  • Container Hosting — EC2, Cloud Run, App Platform, or Kubernetes
  • Load Balancer — ALB, Cloud Load Balancing, or built-in

AWS Deployment

1. Create RDS PostgreSQL

aws rds create-db-instance \
  --db-instance-identifier logstack-db \
  --db-instance-class db.t3.small \
  --engine postgres \
  --engine-version 16 \
  --master-username logstack \
  --master-user-password YOUR_PASSWORD \
  --allocated-storage 50 \
  --vpc-security-group-ids sg-xxxxxxxx

2. Create ElastiCache Redis

aws elasticache create-cache-cluster \
  --cache-cluster-id logstack-redis \
  --cache-node-type cache.t3.micro \
  --engine redis \
  --num-cache-nodes 1

3. Launch EC2 Instance

# Launch t3.medium with Ubuntu 22.04
aws ec2 run-instances \
  --image-id ami-xxxxxxxxx \
  --instance-type t3.medium \
  --key-name your-key \
  --security-group-ids sg-xxxxxxxx

4. Configure Environment

# SSH to instance
ssh -i your-key.pem ubuntu@ec2-xx-xx-xx-xx.compute-1.amazonaws.com
 
# Install Docker
curl -fsSL https://get.docker.com | sh
sudo usermod -aG docker ubuntu
 
# Clone and configure
git clone https://github.com/mosesedem/logstack.git
cd logstack
cp .env.example .env
 
# Update .env with RDS and ElastiCache endpoints
DATABASE_URL=postgres://logstack:PASSWORD@logstack-db.xxxxx.rds.amazonaws.com:5432/logstack
REDIS_URL=redis://logstack-redis.xxxxx.cache.amazonaws.com:6379

5. Deploy

docker-compose up -d
WorkloadInstancevCPUMemory
Developmentt3.micro21 GB
Smallt3.small22 GB
Mediumt3.medium24 GB
Productiont3.large28 GB
High-trafficc6i.xlarge48 GB

Load Balancer Setup

For high availability, add a load balancer:

# AWS ALB
aws elbv2 create-load-balancer \
  --name logstack-lb \
  --subnets subnet-xxxxx subnet-yyyyy \
  --security-groups sg-xxxxxxxx
 
# Configure target groups and listeners...

For production, always use HTTPS with valid SSL certificates.

Auto-Scaling

Docker Swarm

services:
  api:
    deploy:
      replicas: 3
      resources:
        limits:
          cpus: "1"
          memory: 1G

Kubernetes

See our Kubernetes deployment guide (coming soon) for:

  • Helm charts
  • Horizontal Pod Autoscaler
  • Ingress configuration