Infrastructure
This page documents the AWS infrastructure provisioned by Terraform for the qa-automation service.
All resources are defined in the deploy/ directory and are applied exclusively to the test environment via GitHub Actions.
The infrastructure is managed using the fmtf-module-lambda internal module and the terraform-aws-modules/apigateway-v2 community module.
| This service is deployed exclusively to the test environment and is never deployed to production. |
Lambda Functions
One Lambda function is deployed.
It is built from the cmd/api entrypoint, packaged as a binary in dist/, and deployed using the internal fmtf-module-lambda module (v2.0.1).
| Function | Trigger | Timeout | Memory | Key IAM Permissions |
|---|---|---|---|---|
|
API Gateway HTTP API (AWS IAM SigV4) — |
300s |
Module default |
|
Environment Variables
The Lambda receives the following runtime configuration via environment variables:
| Variable | Value / Source |
|---|---|
|
|
|
Hardcoded at deploy time |
|
Hardcoded at deploy time |
|
|
|
|
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
Resolved from |
|
|
|
|
|
|
|
|
|
|
|
|
|
SQS URL for scheduled subscription collections queue |
|
SQS URL for paused subscription collections queue |
|
SQS URL for retry subscription collections queue |
|
SQS URL for webhook subscription collections queue |
|
SQS URL for subscription notifier worker queue |
|
SQS URL for daily float collections queue |
|
SQS URL for webhook float collections queue |
API Gateway
The HTTP API (API Gateway v2) is provisioned using the terraform-aws-modules/apigateway-v2 module (v6.1.0).
| Property | Value |
|---|---|
Name |
|
Protocol |
HTTP API (API Gateway v2) |
Custom domain |
Not configured ( |
Endpoint URL |
Assigned automatically by AWS at deploy time |
Auth type |
|
Integration payload format |
|
Integration timeout |
30,000 ms (30s) |
DynamoDB Tables
The Lambda reads and writes to four DynamoDB tables, all in us-west-2.
These tables are pre-existing (looked up via data sources) and are not created by this service.
| Table | Region | Purpose |
|---|---|---|
|
us-west-2 |
Stores requirement bypass rules used by test flows to skip eligibility checks (e.g., advance eligibility, KYC gates) |
|
us-west-2 |
Subscription billing activity records (current); read and written during subscription lifecycle tests |
|
us-west-2 |
Historical billing activity; queried during subscription history assertions in tests |
|
us-west-2 |
Underwriting decision records used during underwriting flow tests |
Secrets Manager
All secrets are stored in AWS Secrets Manager under the test/ path prefix and are referenced by name in the Lambda’s environment.
The Lambda retrieves them at startup via secretsmanager:GetSecretValue.
| Secret name (path) | Environment variable | Contents |
|---|---|---|
|
|
Auth0 credentials — client ID, client secret, and domain used to obtain tokens for test user authentication flows |
|
|
Primary RDS database credentials — host, port, username, and password for direct DB access during test setup and teardown |
|
|
Plaid API credentials — client ID and secret for simulating bank link and transaction flows in the test environment |
|
|
GrowthBook SDK key and API credentials used to read and override feature flag state during tests |
|
|
Iterable server-side API key for verifying email and push notification events triggered by test flows |
|
|
Iterable mobile (JWT) API key used to authenticate mobile-originated notification events in tests |
|
(Terraform only — not injected into Lambda) |
Datadog |
VPC
The Lambda runs inside the FloatMe shared VPC in us-west-2.
Subnet and security group resources are looked up by tag name at deploy time rather than hardcoded by ID.
| Resource | Details |
|---|---|
Private Subnet 1 |
Tagged |
Private Subnet 2 |
Tagged |
Security Group |
Tagged |
Placing the Lambda in private subnets ensures it can reach RDS and other internal services over the VPC network without exposing them to the public internet.
Datadog
Monitoring is enabled through the fmtf-module-lambda module, which provisions CloudWatch-based monitors forwarded to Datadog via the Datadog Lambda Extension.
Three Service Level Objectives (SLOs) are defined for the qa-api Lambda, each with 7-day and 30-day windows.
| SLO | Monitor type | Thresholds (target / warning) |
|---|---|---|
|
Monitor-based (error rate) |
99.9% / 99.99% over 7d and 30d |
|
Monitor-based (invocation count) |
99.9% / 99.99% over 7d and 30d |
|
Monitor-based (duration) |
99.9% / 99.99% over 7d and 30d |
A Datadog service definition (schema v2.2) is also registered for the qa service, linking it to:
-
Tier: 1
-
Team: devops
-
Support channel:
#CMWE5RX8Bon Slack -
Source repository: https://github.com/floatme-corp/qa-automation
Datadog credentials (api_key, app_key) are sourced from test/datadog/terraform in Secrets Manager and are used only by the Terraform provider — they are not injected into the Lambda runtime.