MCP.so
Sign In

Terraform MCP Assistant

@jashkahar

Basic information

Category

Cloud & Infrastructure

Transports

stdio

Author

jashkahar

About Terraform MCP Assistant

This project provides an MCP (Model Context Protocol) server that exposes Terraform infrastructure-as-code operations through natural language. It enables LLMs to execute Terraform commands and retrieve information about infrastructure without requiring specific command syntax kn

Terraform MCP Assistant config

Add this server to your MCP-compatible client using the configuration below.

{
  "mcpServers": {
    "Terraform-MCP-Server": {
      "command": "python",
      "args": [
        "-m",
        "venv",
        ".venv"
      ]
    }
  }
}

Terraform MCP Assistant tools

Tool list not available yet

This listing does not currently have a tool list to display. This does not mean the server has no tools; check its documentation for supported capabilities.

We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.

Overview

What is Terraform MCP Assistant?

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

How to use Terraform MCP Assistant?

Clone the repository, create and activate a Python virtual environment, and install dependencies. Optionally install Graphviz for plan visualization. Set the TERRAFORM_WORKSPACE environment variable to point to your Terraform workspace, then place your Terraform configuration files there. Start the MCP server by running python src/main.py and issue commands like "Initialize the Terraform workspace" or "Apply the configuration".

Key features of Terraform MCP Assistant

  • 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

Use cases of Terraform MCP Assistant

  • Initialize a Terraform workspace with a single English command
  • Preview changes before applying ("What will change if I apply?")
  • Inspect and manage current infrastructure state
  • Deploy or destroy all resources using natural language
  • List all resources in the workspace

Frequently asked questions

1

What are the prerequisites?

You need Python 3, a virtual environment, and a Terraform workspace directory with your configuration files. Optional: Graphviz for plan visualization.

2

How do I start the server?

Run `python src/main.py` from the project root after installing dependencies and configuring the environment.

3

What kind of commands can I use?

You can use natural language commands such as "Initialize the Terraform workspace", "Show me the current state", "Apply the configuration", and "Destroy the infrastructure".

Comments

More Cloud & Infrastructure MCP servers