Cover image
Try Now
2025-03-31

该项目提供了MCP(模型上下文协议)服务器,该服务器通过自然语言揭示Terraform基础架构AS代码操作。它使LLM可以执行TerraForm命令并检索有关基础结构的信息,而无需特定的命令语法知识。

3 years

Works with Finder

1

Github Watches

1

Github Forks

2

Github Stars

Terraform MCP Assistant

A FastMCP-based server that provides natural language interface to Terraform operations. This assistant allows you to manage your infrastructure using simple English commands instead of remembering specific Terraform syntax.

Features

  • Natural language processing of Terraform commands
  • Execution plan visualization
  • State inspection and management
  • Infrastructure deployment and destruction
  • Configuration documentation
  • Automatic workspace validation
  • Error handling and formatted output

Installation

  1. Clone the repository:
git clone https://github.com/yourusername/terraform-mcp-server.git
cd terraform-mcp-server
  1. Create and activate a virtual environment:
python -m venv .venv
source .venv/bin/activate  # On Windows: .venv\Scripts\activate
  1. Install dependencies:
pip install -r requirements.txt
  1. Optional: Install Graphviz for plan visualization:
  • Windows: Download from Graphviz Download Page
  • Linux: sudo apt-get install graphviz
  • macOS: brew install graphviz

Configuration

  1. Set up environment variables (optional):
export TERRAFORM_WORKSPACE="/path/to/terraform/workspace"
export LOG_LEVEL="INFO"
  1. Place your Terraform configuration files in the workspace directory.

Usage

  1. Start the MCP server:
python src/main.py
  1. Example commands:
  • "Initialize the Terraform workspace"
  • "What will change if I apply?"
  • "Show me the current state"
  • "Apply the configuration"
  • "List all resources"
  • "Destroy the infrastructure"

Project Structure

terraform-mcp-assistant/
├── docs/                  # Documentation
├── examples/             # Example Terraform configurations
├── src/                  # Source code
│   ├── handlers/        # Command handlers
│   ├── main.py         # Entry point
│   └── config.py       # Configuration management
├── tests/               # Test files
├── .env                # Environment variables (not in VCS)
└── README.md           # This file

Development

  1. Install development dependencies:
pip install -r requirements-dev.txt
  1. Run tests:
pytest

Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a Pull Request

相关推荐

  • NiKole Maxwell
  • I craft unique cereal names, stories, and ridiculously cute Cereal Baby images.

  • Joshua Armstrong
  • Confidential guide on numerology and astrology, based of GG33 Public information

  • https://suefel.com
  • Latest advice and best practices for custom GPT development.

  • Emmet Halm
  • Converts Figma frames into front-end code for various mobile frameworks.

  • Elijah Ng Shi Yi
  • Advanced software engineer GPT that excels through nailing the basics.

  • Alexandru Strujac
  • Efficient thumbnail creator for YouTube videos

  • Daren White
  • A supportive coach for mastering all Spanish tenses.

  • J. DE HARO OLLE
  • Especialista en juegos de palabras en varios idiomas.

  • albert tan
  • Japanese education, creating tailored learning experiences.

  • https://maiplestudio.com
  • Find Exhibitors, Speakers and more

  • Yusuf Emre Yeşilyurt
  • I find academic articles and books for research and literature reviews.

  • apappascs
  • 发现市场上最全面,最新的MCP服务器集合。该存储库充当集中式枢纽,提供了广泛的开源和专有MCP服务器目录,并提供功能,文档链接和贡献者。

  • ShrimpingIt
  • MCP系列GPIO Expander的基于Micropython I2C的操作,源自ADAFRUIT_MCP230XX

  • pontusab
  • 光标与风浪冲浪社区,查找规则和MCP

  • av
  • 毫不费力地使用一个命令运行LLM后端,API,前端和服务。

  • rahulc0dy
  • 测试您的MCP服务器。

  • jae-jae
  • MCP服务器使用剧作《无头浏览器》获取网页内容。

  • ravitemer
  • 一个功能强大的Neovim插件,用于管理MCP(模型上下文协议)服务器

  • patruff
  • Ollama和MCP服务器之间的桥梁,使本地LLMS可以使用模型上下文协议工具

  • HiveNexus
  • 一个适用于中小型团队的AI聊天机器人,支持DeepSeek,Open AI,Claude和Gemini等车型。 专为中小团队设计的ai聊天应用,支持deepSeek,打开ai,claude,双子座等模型。

  • JackKuo666
  • 🔍使AI助手可以通过简单的MCP接口搜索和访问PYPI软件包信息。

    Reviews

    5 (1)
    Avatar
    user_UW2gW5D4
    2025-04-16

    MCP Reporter by cyanheads is an essential tool for any MCP enthusiast. Its intuitive design and seamless integration make data reporting a breeze. The user-friendly interface ensures you can get started quickly without any hassle. Highly recommend for anyone looking to streamline their MCP usage. Check it out at: https://mcp.so/server/mcp-reporter/cyanheads.