Skip to content
Graphviz (DOT) templates

AWS Architecture

VPC with public + private subnets, ALB, EC2, RDS, S3, Lambda.

Template previewGraphviz (DOT)
Rendering…

Make it your own.

digraph AWS {
  rankdir=LR;
  graph [bgcolor="transparent", splines=spline, fontname="Inter", nodesep=0.4, ranksep=0.7];
  node [shape=box, style="rounded,filled", fontname="Inter", fontsize=11];

  Route53 [fillcolor="#fde68a", label="Route 53\n(DNS)"];
  CF [fillcolor="#fde68a", label="CloudFront\n(CDN)"];

  subgraph cluster_vpc {
    label="VPC 10.0.0.0/16"; color="#7c3aed"; style=rounded; fontname="Inter"; fontsize=12;

    subgraph cluster_public {
      label="Public subnet"; color="#1f47f5"; style="rounded,filled"; fillcolor="#eef4ff";
      ALB [fillcolor="white", label="Application\nLoad Balancer"];
      NAT [fillcolor="white", label="NAT Gateway"];
    }
    subgraph cluster_private {
      label="Private subnet"; color="#16a34a"; style="rounded,filled"; fillcolor="#ecfdf5";
      EC2a [fillcolor="white", label="EC2 #1"];
      EC2b [fillcolor="white", label="EC2 #2"];
      Lambda [fillcolor="#fff7ed", label="Lambda\n(workers)"];
    }
    subgraph cluster_data {
      label="Data subnet"; color="#7c3aed"; style="rounded,filled"; fillcolor="#f5f3ff";
      RDS [fillcolor="white", label="RDS Postgres\n(Multi-AZ)"];
      ElastiCache [fillcolor="white", label="ElastiCache\nRedis"];
    }
  }

  S3 [fillcolor="#f0fdf4", label="S3\nstatic assets"];
  SQS [fillcolor="#fff7ed", label="SQS"];

  Route53 -> CF -> ALB;
  CF -> S3 [label="static"];
  ALB -> EC2a; ALB -> EC2b;
  EC2a -> RDS; EC2b -> RDS;
  EC2a -> ElastiCache; EC2b -> ElastiCache;
  EC2a -> SQS -> Lambda;
  Lambda -> RDS;
  EC2a -> NAT [style=dashed, label="egress"];
}