Cloud Deployment
Deploy DuraGraph on any cloud provider with full control over your infrastructure. DuraGraph is designed to be cloud-agnostic and runs anywhere you can deploy containers.
Deployment Options
Section titled “Deployment Options”☁️ Any Cloud Provider
Section titled “☁️ Any Cloud Provider”DuraGraph runs on any cloud that supports Docker containers:
- AWS - ECS, EKS, EC2
- Google Cloud - Cloud Run, GKE, Compute Engine
- Azure - Container Apps, AKS, VMs
- DigitalOcean - App Platform, Kubernetes
- Fly.io - Global edge deployment
- Railway - Simple container hosting
- Render - Managed infrastructure
🏢 On-Premises
Section titled “🏢 On-Premises”Deploy in your own data center with:
- Docker Compose for single-node deployments
- Kubernetes for production clusters
- Air-gapped environments supported
🌐 Hybrid
Section titled “🌐 Hybrid”Mix cloud and on-premises deployments:
- Manage multiple environments from a single dashboard
- Federated execution across regions
- Data residency compliance
Quick Deploy
Section titled “Quick Deploy”One-Click Deploy Buttons
Section titled “One-Click Deploy Buttons”Docker Compose
Section titled “Docker Compose”# Clone and deploygit clone https://github.com/duragraph/duragraph.gitcd duragraphdocker-compose up -dKubernetes
Section titled “Kubernetes”# Using Helmhelm repo add duragraph https://charts.duragraph.aihelm install duragraph duragraph/duragraphCloud-Specific Guides
Section titled “Cloud-Specific Guides”AWS Deployment
Section titled “AWS Deployment”ECS with Fargate
# Create ECS clusteraws ecs create-cluster --cluster-name duragraph
# Deploy using CDK or CloudFormationcd deploy/awscdk deployManaged Database Options:
- Amazon RDS for PostgreSQL
- Amazon ElastiCache for Redis (optional caching)
- Amazon MSK or self-managed NATS
Google Cloud Deployment
Section titled “Google Cloud Deployment”Cloud Run
# Build and push imagegcloud builds submit --tag gcr.io/PROJECT_ID/duragraph
# Deploy to Cloud Rungcloud run deploy duragraph \ --image gcr.io/PROJECT_ID/duragraph \ --platform managed \ --allow-unauthenticatedManaged Database Options:
- Cloud SQL for PostgreSQL
- Memorystore for Redis
Azure Deployment
Section titled “Azure Deployment”Container Apps
# Create container appaz containerapp create \ --name duragraph \ --resource-group myResourceGroup \ --image duragraph/duragraph:latest \ --target-port 8080 \ --ingress externalManaged Database Options:
- Azure Database for PostgreSQL
- Azure Cache for Redis
Infrastructure Requirements
Section titled “Infrastructure Requirements”Minimum Requirements
Section titled “Minimum Requirements”| Component | Requirement |
|---|---|
| CPU | 2 vCPUs |
| Memory | 4GB RAM |
| Storage | 20GB SSD |
| Database | PostgreSQL 14+ |
Recommended Production
Section titled “Recommended Production”| Component | Requirement |
|---|---|
| CPU | 4+ vCPUs |
| Memory | 8GB+ RAM |
| Storage | 100GB+ SSD |
| Database | PostgreSQL 14+ with replicas |
| NATS | JetStream enabled |
Environment Variables
Section titled “Environment Variables”# RequiredDATABASE_URL=postgresql://user:pass@host:5432/duragraphNATS_URL=nats://localhost:4222
# OptionalPORT=8080LOG_LEVEL=infoAUTH_ENABLED=falseSecurity Considerations
Section titled “Security Considerations”Network Security
Section titled “Network Security”- Use private subnets for database and NATS
- Enable TLS for all external connections
- Configure firewall rules appropriately
Authentication
Section titled “Authentication”DuraGraph supports multiple authentication methods:
# JWT AuthenticationAUTH_ENABLED=trueJWT_SECRET=your-secret-key
# OAuth/OIDC (coming soon)OAUTH_PROVIDER=googleOAUTH_CLIENT_ID=...OAUTH_CLIENT_SECRET=...Encryption
Section titled “Encryption”- In Transit: TLS 1.3 for all connections
- At Rest: Use cloud provider’s encryption (RDS encryption, etc.)
Monitoring
Section titled “Monitoring”Prometheus Metrics
Section titled “Prometheus Metrics”DuraGraph exposes Prometheus metrics at /metrics:
scrape_configs: - job_name: 'duragraph' static_configs: - targets: ['duragraph:8080']Health Checks
Section titled “Health Checks”# Liveness probecurl http://localhost:8080/health
# Readiness probecurl http://localhost:8080/healthHigh Availability
Section titled “High Availability”Multi-Region Deployment
Section titled “Multi-Region Deployment”apiVersion: apps/v1kind: Deploymentmetadata: name: duragraphspec: replicas: 3 strategy: type: RollingUpdate template: spec: topologySpreadConstraints: - maxSkew: 1 topologyKey: topology.kubernetes.io/zone whenUnsatisfiable: DoNotScheduleDatabase Replication
Section titled “Database Replication”Configure PostgreSQL with read replicas for high availability:
# PrimaryDATABASE_URL=postgresql://primary:5432/duragraph
# Read replicas (for queries)DATABASE_READ_URL=postgresql://replica:5432/duragraphCost Optimization
Section titled “Cost Optimization”Right-Sizing
Section titled “Right-Sizing”Start small and scale based on actual usage:
| Workload | Recommended Instance |
|---|---|
| Development | t3.small / e2-small |
| Production (small) | t3.large / e2-standard-2 |
| Production (large) | m5.xlarge / n2-standard-4 |
Spot/Preemptible Instances
Section titled “Spot/Preemptible Instances”Use spot instances for non-critical workloads:
# EKS spot instancesnodeSelector: lifecycle: Ec2SpotNext Steps
Section titled “Next Steps”- Self-Hosted Installation — Detailed self-hosted setup
- Getting Started — Quick start guide
- Observability — Set up monitoring
- Architecture Overview — System design