IPI Provisioner Server
БесплатноНе проверенAn MCP server for OpenShift Baremetal IPI cluster provisioning, allowing users to generate and validate install-config.yaml files, test BMC connectivity, valida
Описание
An MCP server for OpenShift Baremetal IPI cluster provisioning, allowing users to generate and validate install-config.yaml files, test BMC connectivity, validate networks, and manage cluster installation lifecycle.
README
An MCP (Model Context Protocol) server for OpenShift Baremetal IPI (Installer-Provisioned Infrastructure) cluster provisioning. This tool helps you generate, validate, and manage install-config.yaml files, test BMC connectivity, validate network configurations, and guide you through the cluster installation process.
Features
- Install Config Management: Generate and validate install-config.yaml files
- BMC Testing: Test Redfish/IPMI BMC connectivity
- Network Validation: Validate CIDR ranges, VIPs, and DNS configuration
- Cluster Lifecycle: Extract installer, create manifests, and manage installations
- Templates: Pre-built templates for Compact and HA deployments
Architecture
ipi-provisioner-mcp/
├── mcp_server/
│ ├── config.py # Configuration and environment variables
│ ├── main.py # FastMCP server setup
│ ├── models/ # Pydantic data models
│ │ ├── install_config.py # InstallConfig models
│ │ ├── baremetal.py # Baremetal host models
│ │ └── network.py # Network configuration models
│ ├── services/ # Business logic
│ │ ├── validation_service.py # Config validation
│ │ ├── bmc_service.py # BMC operations
│ │ ├── network_service.py # Network validation
│ │ └── openshift_service.py # Installer operations
│ ├── tools/ # MCP tool implementations
│ │ ├── config_tools.py # Config generation/validation
│ │ ├── bmc_tools.py # BMC testing
│ │ ├── network_tools.py # Network validation
│ │ └── cluster_tools.py # Cluster lifecycle
│ └── utils/ # Utilities
│ ├── yaml_handler.py # YAML operations
│ └── templates.py # Template management
├── templates/ # Install-config templates
│ ├── baremetal-ipi-compact.yaml
│ └── baremetal-ipi-ha.yaml
└── tests/ # Unit tests
Available MCP Tools
Config Generation & Validation (6 tools)
validate_install_config- Validate install-config.yaml contentgenerate_install_config- Generate install-config.yaml from parametersget_config_template- Get a pre-built templatelist_config_templates- List all available templatescreate_baremetal_host_entry- Create a host entry for install-config
BMC Operations (4 tools)
test_bmc_connection- Test single BMC connectivity (Redfish)validate_bmc_addresses- Validate multiple BMC addressesparse_bmc_address- Parse and validate BMC address formatgenerate_bmc_test_script- Generate bash script for BMC testing
Network Validation (8 tools)
validate_network_cidr- Validate CIDR notationcheck_ip_in_network- Check if IP is in CIDR rangecheck_network_overlap- Check if two networks overlapvalidate_vip_configuration- Validate VIP configurationgenerate_dns_config- Generate DNS records for clustercalculate_cluster_network_capacity- Calculate pod network capacitygenerate_network_diagram- Generate network diagramvalidate_complete_network_config- Comprehensive network validation
Cluster Lifecycle (6 tools)
check_installer_binary- Check if openshift-install existsextract_openshift_installer- Extract installer from release imagecreate_installation_manifests- Create Kubernetes manifestsprepare_cluster_installation- Prepare installation commandprepare_cluster_destroy- Prepare cluster destroy commandget_installation_status- Get installation statusget_installation_logs- Get installation logs
Installation
cd /Users/jhajyahy/mcp/ipi-provisioner-mcp
uv sync # Creates venv and installs dependencies
source .venv/bin/activate # On Windows: .venv\Scripts\activate
Configuration
Environment Variables (Optional)
# OpenShift Configuration
export OPENSHIFT_RELEASE_IMAGE="quay.io/openshift-release-dev/ocp-release:4.17.0-x86_64"
export PULL_SECRET_PATH="$HOME/pull-secret.json"
export SSH_KEY_PATH="$HOME/.ssh/id_rsa.pub"
# MCP Transport (default: stdio)
export MCP_TRANSPORT="stdio" # or "sse" for web-based integration
export MCP_HOST="127.0.0.1" # for sse transport
export MCP_PORT="8000" # for sse transport
MCP Client Configuration
Claude Desktop / Cursor IDE
Add to your ~/.config/claude-desktop/mcp.json or ~/.cursor/mcp.json:
{
"mcpServers": {
"ipi-provisioner": {
"command": "uv",
"args": ["run", "python", "/Users/jhajyahy/mcp/ipi-provisioner-mcp/main.py"],
"description": "IPI Cluster Provisioning Assistant for OpenShift Baremetal",
"env": {
"OPENSHIFT_RELEASE_IMAGE": "quay.io/openshift-release-dev/ocp-release:4.17.0-x86_64",
"PULL_SECRET_PATH": "/path/to/pull-secret.json",
"SSH_KEY_PATH": "/path/to/id_rsa.pub"
}
}
}
}
Usage Examples
1. List Available Templates
User: List available install-config templates
Response shows Compact and HA templates with descriptions.
2. Generate Install Config
User: Generate an install-config for a 3-master HA cluster named 'prod-cluster'
with base domain 'example.com', API VIP 192.168.1.10, Ingress VIP 192.168.1.11
3. Validate Install Config
User: Validate this install-config.yaml:
[paste your config]
Returns validation errors, warnings, and a summary.
4. Test BMC Connectivity
User: Test BMC connection to redfish://192.168.1.100 with username admin and password secret
5. Validate Network Configuration
User: Validate network config with cluster CIDR 10.128.0.0/14, service CIDR 172.30.0.0/16,
machine CIDR 192.168.1.0/24, API VIP 192.168.1.10, Ingress VIP 192.168.1.11
6. Generate DNS Configuration
User: Generate DNS config for cluster 'ocp' with base domain 'example.com',
API VIP 192.168.1.10, Ingress VIP 192.168.1.11, and hosts:
- master-0 with IP 192.168.1.20
- master-1 with IP 192.168.1.21
- master-2 with IP 192.168.1.22
This will generate A and PTR records for all cluster components including the API VIP, Ingress VIP, and all hosts.
7. Extract OpenShift Installer
User: Extract openshift-install from release image
quay.io/openshift-release-dev/ocp-release:4.17.0-x86_64
8. Check Installation Status
User: Get installation status for /path/to/install-dir
Common Workflows
Workflow 1: Validate Existing Config
- Validate config:
validate_install_config(yaml_content) - Validate networks:
validate_complete_network_config(...) - Validate BMCs:
validate_bmc_addresses(hosts) - Generate DNS config:
generate_dns_config(...)
Workflow 2: Troubleshoot Installation
- Check status:
get_installation_status(install_dir) - Get logs:
get_installation_logs(install_dir, lines=100) - Validate network:
validate_complete_network_config(...) - Test BMCs:
validate_bmc_addresses(hosts)
Testing
Run the test suite:
uv run pytest tests/ -v
Templates
Available Templates
baremetal-ipi-compact.yaml - Compact Cluster
- 3 master nodes (also act as workers)
- Requires API and Ingress VIPs
- Good for resource-constrained environments
baremetal-ipi-ha.yaml - High Availability
- 3 master nodes
- 2+ dedicated worker nodes
- Requires API and Ingress VIPs
- Production-ready configuration
Network Requirements
Machine Network
- Physical network for baremetal hosts
- Contains API VIP and Ingress VIP (for HA)
- Example: 192.168.1.0/24
Cluster Network (Pod Network)
- Virtual network for pod-to-pod communication
- Example: 10.128.0.0/14
- Each node gets a /23 subnet (510 IPs per node)
Service Network
- Virtual network for Kubernetes services
- Example: 172.30.0.0/16
DNS Requirements (HA/Compact)
A Records
api.<cluster_name>.<base_domain>→ API VIP*.apps.<cluster_name>.<base_domain>→ Ingress VIP (wildcard)<hostname>.<base_domain>→ Host IP (for each cluster node)
PTR Records (Reverse DNS)
- API VIP →
api.<cluster_name>.<base_domain> - Each host IP →
<hostname>.<base_domain>
Example for cluster 'ocp' with domain 'example.com':
# A Records
api.ocp.example.com. A 10.1.235.200
*.apps.ocp.example.com. A 10.1.235.201
master-0.example.com. A 10.1.235.25
master-1.example.com. A 10.1.235.26
master-2.example.com. A 10.1.235.27
# PTR Records
200.235.1.10.in-addr.arpa. PTR api.ocp.example.com.
25.235.1.10.in-addr.arpa. PTR master-0.example.com.
26.235.1.10.in-addr.arpa. PTR master-1.example.com.
27.235.1.10.in-addr.arpa. PTR master-2.example.com.
BMC Requirements
Supported BMC Types
- Redfish (recommended)
- Redfish Virtual Media
- IPMI
- iDRAC Virtual Media
BMC Address Format
- Redfish:
redfish://192.168.1.100orredfish+https://192.168.1.100:443 - IPMI:
ipmi://192.168.1.100
Troubleshooting
Common Issues
BMC Connection Failures
- Use
test_bmc_connectionto verify connectivity - Check BMC credentials
- Verify network connectivity to BMC
- Use
Network Validation Errors
- Use
validate_complete_network_configto check for overlaps - Ensure VIPs are in machine network range
- Verify DNS is configured correctly
- Use
Installation Failures
- Use
get_installation_logsto check logs - Verify all BMCs are reachable
- Check network configuration
- Ensure DNS records exist (for HA)
- Use
Contributing
Contributions are welcome! Please ensure:
- All tests pass:
uv run pytest tests/ -v - Code follows existing patterns
- Add tests for new functionality
License
Apache 2.0
Built for OpenShift Metal Platform Team
Установка IPI Provisioner Server
У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.
▸ github.com/redhat-community-ai-tools/openshift-ipi-mcpFAQ
IPI Provisioner Server MCP бесплатный?
Да, IPI Provisioner Server MCP бесплатный — установка в пару кликов через Unyly без оплаты.
Нужен ли API-ключ для IPI Provisioner Server?
Нет, IPI Provisioner Server работает без API-ключей и переменных окружения.
IPI Provisioner Server — hosted или self-hosted?
Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.
Как установить IPI Provisioner Server в Claude Desktop, Claude Code или Cursor?
Открой IPI Provisioner Server на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.
Похожие MCP
GitHub
PRs, issues, code search, CI status
автор: GitHubFilesystem
Secure file operations with configurable access controls.
Memory
Knowledge graph-based persistent memory system.
Template MCP Server
A CLI tool to create a new Model Context Protocol server project with TypeScript support, dual transport options, and an extensible structure
автор: mcpdotdirectCompare IPI Provisioner Server with
Не уверен что выбрать?
Найди свой стек за 60 секунд
Автор?
Embed-бейдж для README
Похожее
Все в категории development
