You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- VPC, public subnets, private app subnets, and private DB subnets
281
-
- security groups for ALB, app tasks, and RDS
281
+
- private app route table for private ECS task subnets
282
+
- VPC endpoints for private AWS service access:
283
+
- interface endpoints for ECR API, ECR Docker registry, CloudWatch Logs, and Secrets Manager
284
+
- S3 gateway endpoint associated with the private app route table
285
+
- security groups for ALB, app tasks, AWS service interface endpoints, and RDS
282
286
- private RDS PostgreSQL instance
283
287
- RDS-managed database password secret
284
288
- manually-created Secrets Manager secret for `AGENT_CREDENTIAL_HASH_SECRET`
@@ -309,16 +313,21 @@ Verified AWS smoke tests:
309
313
- deployed `docs_tool` denies `doc2` with `DEFAULT_DENY`
310
314
- the deployed tool path resolves a DB-backed registered-agent credential through `X-Agent-Api-Key`
311
315
312
-
Current AWS development limitation:
316
+
Current AWS networking posture:
313
317
314
-
- ECS app tasks currently run in public subnets with `assignPublicIp=ENABLED`.
315
-
- This avoids NAT Gateway or VPC endpoints during the first runnable AWS slice.
316
-
- Inbound access remains restricted through security groups:
317
-
- Internet -> ALB on port `80`
318
-
- ALB -> ECS app task on port `8000`
319
-
- ECS app task -> RDS on port `5432`
318
+
- ALB nodes remain in public subnets and provide the public HTTP entry point.
319
+
- ECS/Fargate app tasks run in private app subnets with `assignPublicIp=DISABLED`.
320
+
- Running app tasks have private IPs only; they are registered with the ALB target group by private task IP.
321
+
- RDS PostgreSQL remains in private DB subnets.
322
+
- Private app task access to required AWS services uses VPC endpoints rather than a NAT Gateway:
323
+
- interface endpoints for ECR API, ECR Docker registry, CloudWatch Logs, and Secrets Manager
324
+
- S3 gateway endpoint associated with the private app route table
325
+
- App task security group egress is limited to required paths:
326
+
- RDS PostgreSQL on port `5432`
327
+
- AWS service interface endpoint security group on port `443`
328
+
- S3 endpoint prefix list on port `443`
320
329
321
-
This is a deliberate development-stage trade-off, not the intended production networking posture.
330
+
No NAT Gateway is currently deployed. That is intentional for this slice because the app does not yet need general outbound internet access to third-party APIs or arbitrary external services.
322
331
323
332
## Operational helper scripts
324
333
@@ -512,7 +521,7 @@ It is not currently trying to be:
512
521
- IdP integration
513
522
- database-backed policy authoring/storage
514
523
- production credential registry UI
515
-
- production-grade AWS networking hardening
524
+
-full production-grade AWS hardening beyond the current portfolio/dev deployment
516
525
517
526
The emphasis is on doing a smaller set of backend/platform concerns properly:
518
527
@@ -538,8 +547,7 @@ Credible next improvements include:
538
547
- extend immutable image tagging consistently across manual and Terraform-driven deployment paths
539
548
- HTTPS listener with ACM certificate
540
549
- optional HTTP-to-HTTPS redirect
541
-
- private ECS task networking without public task IPs
542
-
- NAT Gateway or VPC endpoints for outbound AWS service access
550
+
- optional NAT Gateway or controlled egress path only if future app behaviour requires general external access
543
551
- Terraform remote state backend
544
552
- migration version tracking
545
553
- production-grade registered-agent credential registration and rotation workflow
@@ -564,6 +572,8 @@ Current status:
564
572
- local Docker/PostgreSQL path works
565
573
- local and CI tests pass
566
574
- AWS ECS/RDS/ALB deployment path works
575
+
- ECS app tasks run in private app subnets with no public IP
576
+
- VPC endpoints provide private AWS service access for ECR, CloudWatch Logs, Secrets Manager, and S3
567
577
- AWS RDS migrations run through one-off ECS tasks
568
578
- AWS dev registered-agent credential seeding/rotation works
569
579
- deployed MCP allow and deny paths have been smoke-tested
Copy file name to clipboardExpand all lines: docs/aws_deployment_target.md
+44-14Lines changed: 44 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,17 +2,17 @@
2
2
3
3
## Purpose
4
4
5
-
Define the AWS runtime shape for `aws-python-service-platform` before implementing Terraform.
5
+
Define the implemented AWS runtime shape for `aws-python-service-platform`.
6
6
7
7
## Target runtime path
8
8
9
9
```text
10
10
Client / MCP caller
11
11
-> Application Load Balancer
12
-
-> ECS Fargate service
12
+
-> ECS Fargate service in private app subnets
13
13
-> FastAPI + FastMCP app
14
-
-> RDS PostgreSQL
15
-
-> CloudWatch logs
14
+
-> RDS PostgreSQL in private DB subnets
15
+
-> CloudWatch logs via VPC endpoint
16
16
```
17
17
18
18
## AWS services
@@ -24,6 +24,7 @@ Client / MCP caller
24
24
| Database | RDS PostgreSQL |
25
25
| Secrets | Secrets Manager or SSM Parameter Store |
26
26
| Logs | CloudWatch Logs |
27
+
| Private AWS service access | VPC endpoints for ECR, CloudWatch Logs, Secrets Manager, and S3 |
27
28
| Runtime permissions | ECS task role |
28
29
| Infrastructure | Terraform |
29
30
@@ -43,9 +44,9 @@ The AWS deployment should keep the same application configuration contract used
43
44
44
45
The application code should continue reading configuration through the existing settings module. Terraform and ECS are responsible for supplying the correct runtime values.
45
46
46
-
## Initial deployment scope
47
+
## Implemented deployment scope
47
48
48
-
The first AWS deployment will run the existing service using RDS-backed configuration and CloudWatch logging.
49
+
The current AWS deployment runs the existing service using RDS-backed configuration, CloudWatch logging, private ECS task networking, and VPC endpoints for required AWS-service access.
0 commit comments