Unreal Cloud DDC Infra Module¶
Unreal Cloud Derived Data Cache (source code) is a caching system that stores additional data required to use assets, such as compiled shaders. This allows the engine to quickly retrieve this data instead of having to regenerate it, saving time and disk space for the development team. For distributed teams, a cloud-hosted DDC enables efficient collaboration by ensuring all team members have access to the same cached data regardless of their location. This module deploys the core infrastructure for Unreal Engine's Cloud Derived Data Cache (DDC) on AWS. It creates a scalable, secure, and high-performance environment that optimizes asset processing and distribution throughout your game development pipeline, reducing build times and improving team collaboration.
The Unreal Cloud Derived Data Cache (DDC) infrastructure module implements Epic's recommended architecture using ScyllaDB, a high-performance Cassandra-compatible database. This module provisions the following AWS resources:
-
ScyllaDB Database Layer:
- Deployed on EC2 instances
- Supports both single-node and multi-node cluster configurations
- Optimized for high-throughput DDC operations
- Configured with AWS Systems Manager Session Manager to provide secure shell access without requiring SSH or bastion hosts
-
ScyllaDB Monitoring Stack:
- Deployed on an EC2 instance
- Uses Prometheus for metrics collection, Alertmanager for handling alerts, and Grafana for visualization
- Creates a Application Load Balancer for accessing the Grafana UI for real-time insights into ScyllaDB node performance
-
Amazon EKS Cluster with specialized node groups:
- System node group: Handles core Kubernetes components and system workloads
- NVME node group: Optimized for high-performance storage operations
- Worker node group: Manages regional data replication and distribution
- Configured with AWS Systems Manager Session Manager to provide secure shell access without requiring SSH or bastion hosts
-
S3 Bucket:
- Provides durable storage for cached assets
- Enables cross-region asset availability
- Serves as a persistent backup layer
Deployment Architecture¶
Prerequisites¶
Network Infrastructure Requirements¶
At a minimum, the Cloud DDC Module requires a Virtual Private Cloud (VPC) with a specific subnet configuration. The suggested configuration includes:
- 2 public subnets
- 2 private subnets
- Coverage across 2 Availability Zones
- An S3 interface endpoint
This architecture ensures high availability and secure communication patterns for your DDC infrastructure.
Configuring Node Groups and ScyllaDB Deployment¶
The footprint of your Cloud DDC deployment can be configured through 2 variables:
EKS Node Group Configuration: eks_node_group_subnets
The eks_node_group_subnets
variable defines the subnet distribution for your EKS node groups. Each specified subnet serves as a potential target for node placement, providing granular control over the geographical distribution of your EKS infrastructure. Adding more subnets to this configuration increases deployment flexibility and enables broader availability zone coverage for your workloads at the cost of increased network complexity and potential inter-AZ data transfer charges.
ScyllaDB Instance Distribution: scylla_subnets
The scylla_subnets
variable determines the deployment topology of your ScyllaDB instances. Each specified subnet receives a dedicated ScyllaDB instance, with multiple subnet configurations automatically establishing a distributed cluster architecture. Configurations of two or more subnets enable high availability and data resilience through native ScyllaDB clustering at the cost of increased infrastructure complexity and proportionally higher operational expenses.
Requirements¶
Name | Version |
---|---|
terraform | >= 1.5 |
aws | >= 5.38 |
tls | >= 4.0.5 |
Providers¶
Name | Version |
---|---|
aws | >= 5.38 |
tls | >= 4.0.5 |
Modules¶
No modules.
Resources¶
Inputs¶
Name | Description | Type | Default | Required |
---|---|---|---|---|
eks_cluster_access_cidr | List of the CIDR Ranges you want to grant public access to the EKS Cluster. | list(string) |
n/a | yes |
name | Unreal Cloud DDC Workload Name | string |
"unreal-cloud-ddc" |
no |
nvme_managed_node_desired_size | Desired number of nvme managed node group instances | number |
2 |
no |
nvme_managed_node_instance_type | Nvme managed node group instance type | string |
"i3en.xlarge" |
no |
nvme_managed_node_max_size | Max number of nvme managed node group instances | number |
2 |
no |
peer_cidr_blocks | The peered cidr blocks you want your vpc to communicate with if you have a multi region ddc. | list(string) |
[] |
no |
private_subnets | Private subnets you want scylla and the worker nodes to be installed into. | list(string) |
[] |
no |
scylla_ami_name | Name of the Scylla AMI to be used to get the AMI ID | string |
"ScyllaDB 6.0.1" |
no |
scylla_architecture | The chip architecture to use when finding the scylla image. Valid | string |
"x86_64" |
no |
scylla_db_storage | Size of gp3 ebs volumes attached to Scylla DBs | number |
100 |
no |
scylla_db_throughput | Throughput of gp3 ebs volumes attached to Scylla DBs | number |
200 |
no |
scylla_dns | The local private dns name that you want Scylla to be queryable on. | string |
null |
no |
scylla_instance_type | The type and size of the Scylla instance. | string |
"i4i.2xlarge" |
no |
scylla_private_subnets | The subnets you want Scylla to be installed into. Can repeat subnet ids to install into the same subnet/az. This will also determine how many Scylla instances are deployed. | list(string) |
[] |
no |
system_managed_node_desired_size | Desired number of monitoring managed node group instances. | number |
1 |
no |
system_managed_node_instance_type | Monitoring managed node group instance type. | string |
"m5.large" |
no |
system_managed_node_max_size | Max number of monitoring managed node group instances. | number |
2 |
no |
vpc_id | String for VPC ID | string |
n/a | yes |
worker_managed_node_desired_size | Desired number of worker managed node group instances. | number |
1 |
no |
worker_managed_node_instance_type | Worker managed node group instance type. | string |
"c5.xlarge" |
no |
worker_managed_node_max_size | Max number of worker managed node group instances. | number |
1 |
no |
Outputs¶
Name | Description |
---|---|
cluster_arn | n/a |
cluster_certificate_authority_data | n/a |
cluster_endpoint | n/a |
cluster_name | n/a |
oidc_provider_arn | n/a |
oidc_provider_identity | n/a |
s3_bucket_id | n/a |
Requirements¶
Name | Version |
---|---|
terraform | >= 1.10.3 |
aws | >=5.89.0 |
random | 3.5.1 |
tls | >= 4.0.6 |
Providers¶
Name | Version |
---|---|
aws | 5.99.1 |
random | 3.5.1 |
tls | 4.1.0 |
Modules¶
No modules.
Resources¶
Inputs¶
Name | Description | Type | Default | Required |
---|---|---|---|---|
alb_certificate_arn | The ARN of the certificate to use on the ALB | string |
null |
no |
create_application_load_balancer | Whether to create an application load balancer for the Scylla monitoring dashboard. | bool |
true |
no |
create_scylla_monitoring_stack | Whether to create the Scylla monitoring stack | bool |
true |
no |
debug | Enable debug mode | bool |
false |
no |
eks_cluster_cloudwatch_log_group_prefix | Prefix to be used for the EKS cluster CloudWatch log group. | string |
"/aws/eks/unreal-cloud-ddc/cluster" |
no |
eks_cluster_logging_types | List of EKS cluster log types to be enabled. | list(string) |
[ |
no |
eks_cluster_private_access | Allows private access of the EKS Control Plane from subnets attached to EKS Cluster | bool |
true |
no |
eks_cluster_public_access | Allows public access of EKS Control Plane should be used with | bool |
false |
no |
eks_cluster_public_endpoint_access_cidr | List of the CIDR Ranges you want to grant public access to the EKS Cluster's public endpoint. | list(string) |
[] |
no |
eks_node_group_subnets | A list of subnets ids you want the EKS nodes to be installed into. Private subnets are strongly recommended. | list(string) |
[] |
no |
enable_scylla_monitoring_lb_access_logs | Whether to enable access logs for the Scylla monitoring load balancer. | bool |
false |
no |
enable_scylla_monitoring_lb_deletion_protection | Whether to enable deletion protection for the Scylla monitoring load balancer. | bool |
false |
no |
environment | The current environment (e.g. dev, prod, etc.) | string |
"dev" |
no |
existing_security_groups | List of existing security groups to add to the monitoring and Unreal DDC load balancers | list(string) |
[] |
no |
internal_facing_application_load_balancer | Whether the application load balancer should be internal-facing. | bool |
false |
no |
kubernetes_version | Kubernetes version to be used by the EKS cluster. | string |
"1.31" |
no |
monitoring_application_load_balancer_subnets | The subnets in which the ALB will be deployed | list(string) |
null |
no |
name | Unreal Cloud DDC Workload Name | string |
"unreal-cloud-ddc" |
no |
nvme_managed_node_desired_size | Desired number of nvme managed node group instances | number |
2 |
no |
nvme_managed_node_instance_type | Nvme managed node group instance type | string |
"i3en.large" |
no |
nvme_managed_node_max_size | Max number of nvme managed node group instances | number |
2 |
no |
nvme_managed_node_min_size | Min number of nvme managed node group instances | number |
1 |
no |
nvme_node_group_label | Label applied to nvme node group. These will need to be matched in values for taints and tolerations for the worker pod definition. | map(string) |
{ |
no |
project_prefix | The project prefix for this workload. This is appended to the beginning of most resource names. | string |
"cgd" |
no |
region | The AWS region to deploy to | string |
"us-west-2" |
no |
scylla_ami_name | Name of the Scylla AMI to be used to get the AMI ID | string |
"ScyllaDB 6.0.1" |
no |
scylla_architecture | The chip architecture to use when finding the scylla image. Valid | string |
"x86_64" |
no |
scylla_db_storage | Size of gp3 ebs volumes attached to Scylla DBs | number |
100 |
no |
scylla_db_throughput | Throughput of gp3 ebs volumes attached to Scylla DBs | number |
200 |
no |
scylla_instance_type | The type and size of the Scylla instance. | string |
"i4i.2xlarge" |
no |
scylla_monitoring_instance_storage | Size of gp3 ebs volumes in GB attached to Scylla monitoring instance | number |
20 |
no |
scylla_monitoring_instance_type | The type and size of the Scylla monitoring instance. | string |
"t3.xlarge" |
no |
scylla_monitoring_lb_access_logs_bucket | Name of the S3 bucket to store the access logs for the Scylla monitoring load balancer. | string |
null |
no |
scylla_monitoring_lb_access_logs_prefix | Prefix to use for the access logs for the Scylla monitoring load balancer. | string |
null |
no |
scylla_subnets | A list of subnet IDs where Scylla will be deployed. Private subnets are strongly recommended. | list(string) |
[] |
no |
system_managed_node_desired_size | Desired number of system managed node group instances. | number |
1 |
no |
system_managed_node_instance_type | Monitoring managed node group instance type. | string |
"m5.large" |
no |
system_managed_node_max_size | Max number of system managed node group instances. | number |
2 |
no |
system_managed_node_min_size | Min number of system managed node group instances. | number |
1 |
no |
system_node_group_label | Label applied to system node group | map(string) |
{ |
no |
tags | Tags to apply to resources. | map(any) |
{ |
no |
vpc_id | String for VPC ID | string |
n/a | yes |
worker_managed_node_desired_size | Desired number of worker managed node group instances. | number |
1 |
no |
worker_managed_node_instance_type | Worker managed node group instance type. | string |
"c5.large" |
no |
worker_managed_node_max_size | Max number of worker managed node group instances. | number |
1 |
no |
worker_managed_node_min_size | Min number of worker managed node group instances. | number |
0 |
no |
worker_node_group_label | Label applied to worker node group. These will need to be matched in values for taints and tolerations for the worker pod definition. | map(string) |
{ |
no |
Outputs¶
Name | Description |
---|---|
cluster_arn | ARN of the EKS Cluster |
cluster_certificate_authority_data | Public key for the EKS Cluster |
cluster_endpoint | EKS Cluster Endpoint |
cluster_name | Name of the EKS Cluster |
external_alb_dns_name | DNS endpoint of Application Load Balancer (ALB) |
external_alb_zone_id | Zone ID for internet facing load balancer |
nvme_node_group_label | Label for the NVME node group |
oidc_provider_arn | OIDC provider for the EKS Cluster |
peer_security_group_id | ID of the Peer Security Group |
s3_bucket_id | Bucket to be used for the Unreal Cloud DDC assets |
scylla_ips | IPs of the Scylla EC2 instances |
system_node_group_label | Label for the System node group |
worker_node_group_label | Label for the Worker node group |