AWS Common MCP Servers with CDK Deployment
LocalAbout AWS Common MCP Servers with CDK Deployment
This project provides MCP servers for AWS Location Service, S3, and Aurora PostgreSQL through the RDS Data API, plus AWS CDK code to deploy them. It is intended for AI developers integrating AWS services through MCP.
Key features
- 01Location search, place details, and routes
- 02S3 bucket and object operations
- 03Aurora PostgreSQL SQL execution via Data API
- 04CDK infrastructure deployment to ECS Fargate
Use cases
- 01Search places or calculate routes with Location Service
- 02List, retrieve, upload, or delete S3 objects
- 03Run SQL against an Aurora PostgreSQL cluster
- 04Deploy MCP services in an AWS account
MCP support
It exposes AWS Location Service, S3, and Aurora PostgreSQL operations as tools for MCP clients. AWS CDK code provisions the infrastructure to run the servers, typically on ECS Fargate.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
We haven’t collected a package or remote endpoint for this server. Follow the instructions in the project README.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
From the project READMEAWS Common MCP Servers with CDK Deployment
This project provides deployable Model Context Protocol (MCP) servers for common AWS services, along with AWS Cloud Development Kit (CDK) code (Python) to provision the necessary infrastructure for running these servers, typically on ECS Fargate.
The goal is to offer reusable components that AI developers (e.g., using Amazon Bedrock, LangChain) can easily deploy into their AWS accounts to interact with AWS services through the standardized MCP interface.
Included MCP Servers
- AWS Location Service: (TypeScript) Exposes functionalities like searching places, getting place details, calculating routes, etc. Based on the aws-location-server.
- Amazon S3: (Python) Provides tools for basic S3 operations like listing buckets/objects, getting, putting, and deleting objects.
- Amazon Aurora PostgreSQL (via RDS Data API): (Python) Allows executing SQL statements against a specified Aurora PostgreSQL cluster using the secure RDS Data API.
Prerequisites
- AWS Account
- AWS CLI configured locally with appropriate permissions (for CDK deployment). Credentials should be set up via
~/.aws/credentialsor environment variables. - Node.js and npm (for the Location Service server build process and CDK)
- Python 3.9+ (for CDK and Python-based MCP servers)
- AWS CDK CLI (
npm install -g aws-cdk) - Docker (running locally for CDK to build container images)
- Git
Specific Prerequisites for Aurora PostgreSQL Data API Server:
- An existing Aurora PostgreSQL-Compatible cluster running in your target AWS region.
- The cluster must have the RDS Data API enabled.
- An AWS Secrets Manager secret containing the database credentials (username, password) for the cluster. The ARN of this secret is required for deployment.
Project Structure
aws-mcp-infra/
├── mcp_servers/ # Source code for the MCP servers
│ ├── location_service/ # TypeScript server for AWS Location Service
│ ├── s3/ # Python server for S3
│ └── aurora_pg_data_api/ # Python server for Aurora PG Data API
├── cdk_deployment/ # AWS CDK code (Python)
│ ├── app.py # CDK App entry point
│ ├── cdk.json # CDK configuration
│ ├── requirements.txt # CDK Python dependencies
│ └── aws_mcp_infra/ # CDK Stack definitions
│ ├── __init__.py
│ ├── location_service_stack.py
│ ├── s3_stack.py
│ └── aurora_pg_data_api_stack.py
├── .gitignore
└── README.md # This file
Deployment
- Clone the Repository:
git clone https://github.com/vAirpower/aws-common-mcp-servers.git cd aws-common-mcp-servers - Configure Aurora Prerequisites (if deploying Aurora server):
- Ensure your Aurora PostgreSQL cluster exists and has the Data API enabled.
- Create a secret in AWS Secrets Manager (same region as deployment) containing the DB credentials (e.g., keys
username,password). - Update the
db_cluster_arnanddb_secret_arnvariables incdk_deployment/aws_mcp_infra/aurora_pg_data_api_stack.pywith your specific cluster ARN and the ARN of the secret you created.
- Install CDK Dependencies:
cd cdk_deployment python3 -m venv .venv source .venv/bin/activate pip install -r requirements.txt - Bootstrap CDK (if first time using CDK in this account/region):
cdk bootstrap aws://ACCOUNT-NUMBER/REGION # Replace with your AWS account number and region - Deploy Stacks: Deploy all stacks (creates VPC, Cluster, and all three services):
Or deploy specific stacks:cdk deploy --all --require-approval nevercdk deploy LocationServiceMcpStack S3McpStack AuroraPgDataApiMcpStack --require-approval never
Deployment will build the Docker images for each server, push them to ECR repositories created by CDK, and provision the ECS Fargate services.
Usage
Once deployed, the MCP servers run as tasks within ECS Fargate services. They are not publicly exposed by default. Interaction typically occurs from within your AWS environment:
- From Lambda Functions / Bedrock Agents: Use the AWS SDK (e.g.,
boto3for Python) to invoke the ECS tasks or potentially interact via AWS Systems Manager Session Manager (if configured). The exact mechanism depends on how the client application is designed to communicate with MCP servers running in ECS. - Local Testing (Requires Adaptation): To test these servers locally before deployment, you would typically run them directly (
node build/index.jsorpython aurora_pg_data_api_server.py) after installing their respective dependencies (npm installorpip install -r requirements.txt) and ensuring your local environment has AWS credentials configured. For the Aurora server, you'd also need to set theDB_CLUSTER_ARNandDB_SECRET_ARNenvironment variables locally.
Cleanup
To remove all deployed resources, run:
cd cdk_deployment
source .venv/bin/activate
cdk destroy --all
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.