An MCP server exposing EKS infrastructure details
Project description
MCP EKS Infrastructure Tools
This document describes the Model Context Protocol (MCP) tools available for EKS cluster auditing and infrastructure analysis.
Overview
The EKS Infrastructure MCP Server provides tools to retrieve and analyze Amazon EKS cluster information for auditing and reporting purposes.
Tools
1. getListOfCluster
Description: Retrieves all EKS clusters in the AWS account.
Use Cases:
- Generate audit summaries or reports when cluster information is not available
- List all EKS clusters in the account
- Initial discovery for cluster analysis
Parameters: None
Returns: JSON string containing list of EKS clusters
Example Response:
[
"cluster-1",
"cluster-2",
"production-cluster"
]
2. getEksInfra
Description: Fetches comprehensive EKS cluster infrastructure details including API endpoint, logging configuration, version, encryption settings, and node group information.
Use Cases:
- Generate detailed audit reports for specific clusters
- Analyze cluster infrastructure configuration
- Security and compliance assessments
Parameters:
cluster_name(string, required): Name of the EKS cluster to analyze
Returns: Structured JSON with complete cluster information
Example Response:
{
"cluster_name": "my-cluster",
"status": "ACTIVE",
"version": "1.28",
"endpoint": "https://xxx.eks.region.amazonaws.com",
"roleArn": "arn:aws:iam::account:role/eks-service-role",
"vpc_config": {
"subnetIds": ["subnet-xxx", "subnet-yyy"],
"securityGroupIds": ["sg-xxx"]
},
"logging": {
"clusterLogging": [
{
"types": ["api", "audit"],
"enabled": true
}
]
},
"encryptionConfig": [],
"node_groups": {
"nodegroup-1": {
"version": "1.28",
"status": "ACTIVE",
"capacityType": "ON_DEMAND",
"scalingConfig": {
"minSize": 1,
"maxSize": 3,
"desiredSize": 2
},
"instanceTypes": ["t3.medium"],
"subnets": ["subnet-xxx"],
"remoteAccess": null,
"amiType": "AL2_x86_64"
}
}
}
Setup
Locally
- Set the
AWS_PROFILEenvironment variable to specify the AWS profile to use - Ensure proper AWS credentials and permissions for EKS access
- Run the MCP server:
python mpc_eks_infra.py
UVX
You need to install UV if not already installed
# For Linux and MacOS
curl -LsSf https://astral.sh/uv/install.sh | sh
Config your MCP servers in Claude Desktop, Cursor, ChatGPT Copilot, Github Copilot and other supported AI clients, e.g.
{
"mcpServers": {
"aws-eks-infra": {
"command": "uvx",
"args": [
"eks-infra-mcp"
],
"env": {
"AWS_PROFILE": "<your-aws_profile>"
}
}
}
}
Usage Workflow
- Discovery: Use
getListOfClusterto identify available clusters - Analysis: Use
getEksInfrawith specific cluster names for detailed information - Reporting: Process the returned JSON data for audit reports and compliance checks
Error Handling
Both tools return error information in JSON format when exceptions occur:
{
"error": "Error description"
}
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file eks_infra_mcp-0.1.2.tar.gz.
File metadata
- Download URL: eks_infra_mcp-0.1.2.tar.gz
- Upload date:
- Size: 3.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
db8fdf8219787b88097ec80bf8df60820209740f3edd2ed20b03b24f4e243613
|
|
| MD5 |
987b05e74df7d8fbb160344f788d3a6c
|
|
| BLAKE2b-256 |
14699967c609927fdd46e65bdbda947dede695410c75f55bc3e050175d195f36
|
File details
Details for the file eks_infra_mcp-0.1.2-py3-none-any.whl.
File metadata
- Download URL: eks_infra_mcp-0.1.2-py3-none-any.whl
- Upload date:
- Size: 4.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.5
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
7080553e374f133805a419e924aa4177e55328cd7ac0938c3d22135f155a3c2b
|
|
| MD5 |
bc78b2fd90c47a3dd03b12d901eb23ec
|
|
| BLAKE2b-256 |
733e630d3f369e5fe2f8f1894b327264727ee4ac6084d1d0244625069cf961a0
|