openfeature_provider = "flagd". Obtain a Distribution reader key registered for this deployment from Runlayer before applying. The module’s application default is still WorkOS; setting only the Distribution key and URL does not switch providers.
Quick Start
1. Create the root configuration
Create a working directory and save the following asmain.tf. Replace the account, hostname, parent hosted zone, state bucket, auth client ID, and company details. Pin the module release agreed with Runlayer; this example uses v33.1.0, whose default app version is 1.28.1078.
aws and aws.route53, including when DNS lives in the same account. Cross-account DNS also needs the DNS role and zone ID described in networking.
Terraform marks only five module inputs as required because they have no defaults. This guide also requires the catalog credential and the registered Distribution reader key. Confirm outbound HTTPS to distribution.prod.runlayer.com before startup. Add your selected database, network, security, and optional-feature inputs to this configuration before continuing.
2. Supply credentials
Keep the AWS credential environment from prerequisites. Provide the secret inputs through your secret manager or environment. For an interactive Bash shell, these prompts avoid putting values in shell history:.terraform/, *.tfstate*, *.tfplan, or files containing secrets. Commit .terraform.lock.hcl after initialization.
3. Initialize, validate, and plan
Before planning, review the selected module’s external programs and provisioners. Sentry Relay is enabled by default and its external data source can authenticate with your WorkOS API key and read Relay secrets during the plan. Confirm this credential use and runner access first; see Sentry Relay Vault integration.local-exec provisioners run during resource creation/destruction, not an ordinary
plan, while external data sources can run during planning or be deferred to apply.
terraform init -upgrade to update the lockfile before planning.
4. Apply
anysource-backend-migration-logs-<project>-<environment>. The migration wait defaults to 30 minutes.
This example sets wait_for_ecs_steady_state = true; the module default is false. Even with waiting enabled, complete the checks below: infrastructure readiness does not prove login or connector workflows work.
Verify
Run these commands from the root configuration directory, with the same AWS profile and region:COMPLETED. The AWS waiter has its own timeout; a timeout requires inspecting events and logs. For a private ALB, run HTTP checks from a machine with the required private routing and DNS.
Then verify the user journey:
- Open
terraform output -raw application_url, confirm TLS is valid, and sign in through the configured SSO/WorkOS flow. - Confirm the MCP catalog loads. A catalog
503can indicate a missing API key;401can indicate a wrong key or catalog URL. - Configure an approved test connector, connect an MCP client, and make a harmless tool call. Confirm its session/audit record appears.
- Exercise each feature you enabled: an agent run, ToolGuard scan, or AI Watch package discovery, as applicable. Confirm optional services and load-balancer targets are healthy too.
Troubleshooting
Module or image access denied
Forterraform init, confirm the deployment identity can read the versioned archive in runlayer-infrastructure-modules. For CannotPullContainerError, check ECS events, ECR access to account 088332244652, and the ECR/S3 network paths. Contact Runlayer support if onboarding access is missing.
Migration task failures
anysource-backend-migration-logs-ecs-production for the example configuration, or use your actual project and environment.
Check the migration task’s stopped reason, database connectivity, image permissions, and the AWS CLI credentials inherited by Terraform. After correcting the cause, review a new plan before applying again. Do not disable state locking or force-unlock while another run may still own the lock.
Application not accessible
DomainValidationOptions and verify its exact CNAME name and value in authoritative DNS.
Login works but optional features fail
Check egress symptoms, Bedrock access, and your feature’s configuration. AgentCore behind WAF needs the private network path; ToolGuard needs working GPU bootstrap and capacity.Next Steps
- Updates and rollback
- Backup and restore
- ECS configuration and operations
- Terraform inputs reference
- Module changelog
Related configuration
The following sections retain their existing links and point to the focused guides.Prerequisites
See ECS prerequisites.Private connection provisioning
See private connection provisioning. Connection configuration revision2 is separate from module releases such as v33.1.0.