Tanzu MCP Server
Tanzu MCP Server - AI-powered Cloud Foundry operations via Model Context Protocol
Ask AI about Tanzu MCP Server
Powered by Claude Β· Grounded in docs
I know everything about Tanzu MCP Server. Ask me about installation, configuration, usage, or troubleshooting.
0/500
Reviews
Documentation
Cloud Foundry MCP Server
A comprehensive Model Context Protocol (MCP) server that provides AI-powered access to Cloud Foundry operations through 38 specialized tools. Built with Spring AI 1.1.0 GA and deployed on Cloud Foundry.
Cloud Foundry MCP Server - AI-powered Cloud Foundry operations via Model Context Protocol
π Quick Start
Deploy the Server
- Build and deploy the MCP server to your Cloud Foundry foundation
- Configure your Cloud Foundry credentials in the manifest
- Get the deployed URL from
cf appscommand
MCP Client Configuration
Once deployed, configure your MCP client with the server URL:
{
"mcpServers": {
"tanzu-mcp": {
"disabled": false,
"timeout": 300,
"type": "streamable",
"url": "https://tanzu-mcp-server.apps.your-cf-domain.com/mcp",
"autoApprove": []
}
}
}
Replace your-mcp-server.apps.your-cf-domain.com with your actual deployed server URL.
π Building & Deployment
Build the Server
./mvnw clean package -DskipTests
Deploy to Cloud Foundry
# Copy the template and configure with your credentials
cp manifest-template.yml manifest.yml
# Edit manifest.yml with your CF credentials
cf push tanzu-mcp-server
# Get the deployed URL
cf apps
# Look for your app and copy the URL (e.g., https://tanzu-mcp-server.apps.your-domain.com)
Local Development
# Run with local profile
./mvnw spring-boot:run -Dspring-boot.run.profiles=local
βοΈ Configuration
Environment Variables
CF_APIHOST=api.your-cf-domain.com
CF_USERNAME=your-username
CF_PASSWORD=your-password
CF_ORG=your-organization
CF_SPACE=your-space
Configuration Validation
The server includes automatic configuration validation on startup:
- Required: API host, username, and password must be configured
- Optional: Organization and space (warnings if not set)
- Startup Check: Validates CF connectivity and credentials
- Error Handling: Fails fast with clear error messages if configuration is invalid
Application Properties
spring.ai.mcp.server.name=tanzu-mcp
spring.ai.mcp.server.version=0.1.0
spring.ai.mcp.server.prompt-change-notification=false
spring.ai.mcp.server.resource-change-notification=false
spring.ai.mcp.server.protocol=streamable
management.endpoints.web.exposure.include=health,info,mappings
management.endpoint.health.show-details=always
logging.level.io.modelcontextprotocol=DEBUG
logging.level.org.springframework.ai.mcp=DEBUG
# Cloud Foundry Connection Settings
cf.connection.poolSize=20
cf.connection.keepAlive=true
cf.connection.timeout=30
cf.connection.readTimeout=60
# Cloud Foundry Retry Settings
cf.retry.maxAttempts=3
cf.retry.delay=2
# Cloud Foundry Token Refresh Settings (Note: PasswordGrantTokenProvider handles refresh automatically)
# cf.token.refreshThreshold=5
π Capabilities
This MCP server exposes 38 Cloud Foundry operations as AI-powered tools:
Application Management (8 tools)
- applicationsList - List applications in a CF space
- applicationDetails - Get detailed app information
- pushApplication - Deploy JAR files to CF
- scaleApplication - Scale app instances, memory, disk
- startApplication - Start CF applications
- stopApplication - Stop running applications
- restartApplication - Restart applications
- deleteApplication - Delete applications
Organization & Space Management (8 tools)
- organizationsList - List all organizations
- organizationDetails - Get org details
- spacesList - List spaces in an org
- getSpaceQuota - Get space quota details
- createSpace - Create new spaces
- deleteSpace - Delete spaces
- renameSpace - Rename spaces
- deleteOrphanedRoutes - Clean up orphaned routes
Service Management (7 tools)
- serviceInstancesList - List service instances
- serviceInstanceDetails - Get service instance details
- serviceOfferingsList - List marketplace services
- createServiceInstance - Create new service instances
- bindServiceInstance - Bind services to apps
- unbindServiceInstance - Unbind services from apps
- deleteServiceInstance - Delete service instances
Route Management (6 tools)
- routesList - List routes in a space
- createRoute - Create new routes
- deleteRoute - Delete routes
- mapRoute - Map routes to applications
- unmapRoute - Unmap routes from applications
- deleteOrphanedRoutes - Clean up orphaned routes
Network Policy Management (3 tools)
- addNetworkPolicy - Add network policies between apps
- listNetworkPolicies - List network policies
- removeNetworkPolicy - Remove network policies
Application Cloning (1 tool)
- cloneApp - Clone existing applications with buildpack consistency
Target Management (3 tools)
- targetCf - Set the target organization and space for CF operations
- getCurrentTarget - Get the current target organization and space
- clearTarget - Clear the current target, reverting to configuration defaults
Configuration & Validation (1 tool)
- CfConfigurationValidator - Validates Cloud Foundry configuration on startup
π§ Technical Details
- Spring AI Version: 1.1.0 (GA)
- Spring Boot Version: 3.4.2
- Java Version: 21
- Transport: HTTP Streamable
- Health Endpoint:
/actuator/health - Configuration: Environment variable-based CF credentials
- MCP Java SDK: v0.15.0 (included with Spring AI 1.1.0)
π Health Status
The server provides comprehensive health monitoring:
- Application Health: Memory, disk, CPU usage
- SSL/TLS Status: Certificate validation
- Cloud Foundry Connectivity: API endpoint health with automatic retry logic
- MCP Server Status: Tool registration and transport health
- Connection Pooling: Optimized connection management with keep-alive
- Token Management: Automatic UAA token handling to prevent session expiry
- Retry Logic: Automatic retry for transient network failures
π Current Deployment
Status: β Successfully Deployed and Running
URL: https://tanzu-mcp-server.apps.tp.penso.io
Organization: tanzu-platform-demo
Space: mcp-servers
Application: tanzu-mcp-server
Recent Updates (v0.1.0)
- β Upgraded to Spring AI 1.1.0 GA - Latest stable release with enhanced observability, MCP Java SDK v0.15.0, and improved security integration
- β
Added Target Management Tools - New
targetCf,getCurrentTarget, andclearTargetoperations - β Configuration Validation - Added startup validation for CF credentials and settings
- β Enhanced Error Handling - Better validation and parameter processing
- β Comprehensive Testing - Added unit tests for all new services
- β
Fixed critical service instance creation - Added missing
createServiceInstancemethod - β Improved application push handling - Fixed hardcoded parameter issues
- β Verified all 38 tools - Comprehensive testing of all MCP operations
- β Successful deployment - Application running and healthy on Cloud Foundry
π Security
- Credential Management: Environment variable-based configuration
- SSL/TLS: HTTPS endpoints for secure communication
- Authentication: Cloud Foundry UAA integration
- Authorization: CF role-based access control
π Credential Security
Important: The manifest.yml file contains sensitive credentials and is excluded from git via .gitignore.
- Template: Use
manifest-template.ymlas a starting point - Local Configuration: Copy template and add your credentials
- Environment Variables: Credentials are passed via CF environment variables
- Never Commit: Actual manifest files with credentials should never be committed to git
π Documentation
- Release Notes: RELEASE_NOTES.md
- API Documentation: Comprehensive tool descriptions
- Configuration Guide: Setup and deployment instructions
- Troubleshooting: Common issues and solutions
π€ Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests
- Submit a pull request
π License
This project is licensed under the MIT License.
Built with β€οΈ using Spring AI and Cloud Foundry
