InfraPilot
Allows configuration management and application deployment using Ansible playbooks.
Allows ingesting telemetry data from Prometheus-style sources for monitoring and anomaly detection.
Allows provisioning and management of infrastructure resources using Terraform.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@InfraPilotProvision a web server and audit it for security compliance."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
InfraPilot ๐ฐ๏ธ
Agentic AI for infrastructure operations. A multi-agent system that provisions, monitors, validates compliance and auto-remediates cloud, network and security infrastructure โ built on Python, MCP, CrewAI, Terraform and Ansible.
InfraPilot closes the full ops loop end-to-end: provision โ configure โ observe โ audit โ remediate โ re-audit, coordinated by a crew of specialised AI agents โ and it runs out of the box with no cloud account, no API key and no Terraform/Ansible binaries required (it transparently simulates execution when a binary is absent).
Why it exists
Most "AI for DevOps" demos stop at a chatbot that writes a Terraform snippet. InfraPilot models the operational loop an automation engineer actually owns: turning declarative intent into running infrastructure, watching it, proving it meets security/governance policy, and fixing drift automatically through code โ with every action typed, reported and auditable.
Related MCP server: MCP Cloud Services Server
Architecture
flowchart LR
subgraph Crew["Agent crew"]
P[Provisioner] --> C[Configurator] --> O[Observer] --> A[Compliance Auditor] --> R[Remediator]
end
R -- re-audit --> A
subgraph Tools["Shared tools"]
TF[Terraform tool]
AN[Ansible tool]
MON[Monitoring tool]
POL[Policy-as-code engine]
REM[Remediation strategies]
end
P --> TF
C --> AN
O --> MON
A --> POL
R --> REM
Engines["Engines: native ยท CrewAI"] --- Crew
MCP["MCP server"] --- Tools
LLM["Anthropic Claude (optional)"] -.reasoning.- CrewTwo interchangeable engines.
native(zero heavy deps, drives the loop deterministically, used in CI) andcrewai(maps the same crew onto a CrewAICrewwith an LLM). Swap with--engine.Tools are the source of truth. Terraform, Ansible, monitoring, policy and remediation logic live in
infrapilot/tools/and are shared by every engine and the MCP server โ so there is one implementation, three ways to drive it.MCP-native.
infrapilot/mcp_server/exposes the tools over the Model Context Protocol, so Claude Desktop / Claude Code / any MCP client can run infra operations through natural language.LLM optional. With
ANTHROPIC_API_KEYset, agents use Claude to triage anomalies and justify remediations. Without it, everything still runs.
Quickstart
git clone https://github.com/Gsfrota/infra-pilot && cd infra-pilot
python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
infrapilot demo # fully simulated end-to-end run โ no creds neededExample output (abridged):
โญโโโโโโโโโโโโโโโโโโโโโโโโ InfraPilot run โโโโโโโโโโโโโโโโโโโโโโโโโฎ
โ engine=native llm=off compliance score=100.0/100 โ
โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ
provision ok 4 resources provisioned (simulated)
configure ok configuration applied (simulated)
observe warn 3 anomalies detected
audit error 3 violations, score 43.8
remediate ok 3 fixes applied, score 43.8 -> 100.0Commands
Command | What it does |
| Self-contained simulated run (no cloud/API key/binaries). |
| Full loop; uses real |
| Audit + propose fixes without applying. |
| Drive the crew with CrewAI + Claude. |
| Compliance gate โ exits non-zero on any violation (great in CI). |
Use it from Claude (MCP)
pip install -e ".[mcp]"
infrapilot-mcp # serves the tools over MCP (stdio)// claude_desktop_config.json
{
"mcpServers": {
"infrapilot": { "command": "infrapilot-mcp" }
}
}Then ask Claude: "Provision the infra, audit it for security issues, and remediate anything critical."
How the loop works
Provision โ
TerraformToolappliesinfra/desired_state.yaml(realterraform applyagainst the local/null/random providers when the binary is present; simulated otherwise).Configure โ
AnsibleToolconverges host configuration via a playbook.Observe โ
MonitoringToolingests a Prometheus-style telemetry snapshot and triages anomalies against thresholds.Audit โ the policy-as-code engine evaluates every resource against
policies/policies.yaml; new governance rules are added in YAML, not code.Remediate โ
RemediationToolmaps each violation to a least-privilege fix and applies it through the right IaC backend (Terraform or Ansible).Re-audit โ the loop re-scores compliance to prove the drift is closed.
Policy-as-code
- id: SEC-001
name: "No SSH open to the internet"
severity: critical
resource_type: security_group
rule: no_ingress_cidr
params: { port: 22, forbidden_cidr: "0.0.0.0/0" }
remediation: restrict_sg_ingressBuilt-in rules: required_tag, no_ingress_cidr, attribute_equals,
attribute_max. Built-in remediations: add_tag, restrict_sg_ingress,
enable_encryption, restart_service.
Project layout
infrapilot/
โโโ agents/ # role/goal/backstory crew (engine-agnostic)
โโโ engines/ # native + crewai orchestrators
โโโ tools/ # terraform ยท ansible ยท monitoring ยท compliance ยท remediation
โโโ mcp_server/ # MCP server exposing the tools
โโโ llm.py # optional Anthropic reasoning layer
โโโ reporting.py # rich console + JSON/Markdown artifacts
โโโ cli.py # typer CLI
infra/ # terraform/, ansible/, observability/, desired_state.yaml
policies/ # policy-as-code
tests/ # pytest suite (engine, compliance, monitoring, remediation)Development
pip install -e ".[dev]"
ruff check . # lint
pytest # tests
infrapilot demo # smoke test the full loopCI (GitHub Actions) runs ruff + pytest on 3.10/3.11/3.12 and additionally
installs real Terraform and Ansible to validate/lint the IaC.
Roadmap
Real cloud providers behind a feature flag (AWS/GCP modules)
LangChain tool adapter alongside CrewAI
Drift detection on a schedule (cron / GitHub Actions)
OPA/Rego policy backend option
License
MIT โ see LICENSE.
Built by Guilherme Frota Souza โ automation & AI engineer.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Latest Blog Posts
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/Gsfrota/infra-pilot'
If you have feedback or need assistance with the MCP directory API, please join our Discord server