Azure Citadel
  • Blogs

  • Azure Arc
    • Overview
    • Azure Arc-enabled Kubernetes
      • Prereqs
      • Background
      • Deploy Cluster
      • Connect to Arc
      • Enable GitOps
      • Deploy Application
      • Enable Azure AD
      • Enforce Policy
      • Enable Monitoring
      • Enable Azure Defender
      • Enable Data Services
      • Enable Application Delivery
    • Azure Arc-enabled Servers
      • Prereqs
      • Scenario
      • Hack Overview
      • Azure Landing Zone
      • Arc Pilot resource group
      • Azure Monitoring Agent
      • Additional policy assignments
      • Access your on prem VMs
      • Create onboarding scripts
      • Onboarding using scripts
      • Inventory
      • Monitoring
      • SSH
      • Windows Admin Center
      • Governance
      • Custom Script Extension
      • Key Vault Extension
      • Managed Identity
    • Useful Links
  • Azure CLI
    • Install
    • Get started
    • JMESPATH queries
    • Integrate with Bash
  • Azure landing zone
    • Overview
    • Run the ALZ Accelerator
      • Prereqs
      • Elevate
      • Bootstrap
      • Demote
      • Browse the deployed resources
    • Deploy an Azure landing zone
      • What is the Azure landing zone?
      • Create an initial ALZ config
      • Add a local override library
      • Test locally
      • Run through the CI/CD workflow
    • Understanding libraries
      • What is a library?
      • Policies, Assignments and Roles
      • Archetypes, Overrides and Architecture
      • Metadata and Policy Default Values
      • Custom libraries
    • Reference configs
      • Azure landing zone library
      • Azure landing zone library with overrides
  • Azure Lighthouse
    • Minimal Lighthouse definition
    • Using service principals
    • Privileged Identity Management
  • Azure Policy
    • Azure Policy Basics
      • Policy Basics in the Azure Portal
      • Creating Policy via the CLI
      • Deploy If Not Exists
      • Management Groups and Initiatives
    • Creating Custom Policies
      • Customer scenario
      • Policy Aliases
      • Determine the logic
      • Create the custom policy
      • Define, assign and test
  • Customer Managed Keys
    • Sovereignty scenarios
    • Key management options
    • 🧪 Azure Key Vault Premium
    • L2: Encryption at rest with CMK
    • 🧪 CMK for Storage
    • 🧪 CMK for VM Disks and AKS
  • Marketplace
    • Introduction
      • Terminology
      • Offer Types
    • Partner Center
    • Offer Type
    • Publish a VM Offer HOL
      • Getting Started
      • Create VM Image
      • Test VM Image
      • VM Offer with SIG
      • VM Offer with SAS
      • Publish Offer
      • Other VM Resources
    • Publish a Solution Template HOL
      • Getting Started
      • Create ARM Template
      • Validate ARM Template
      • Create UI Definition
      • Package Assets
      • Publish Offer
    • Publish a Managed App HOL
      • Getting Started
      • Create ARM Template
      • Validate ARM Template
      • Create UI Definition
      • Package Assets
      • Publish Offer
    • Managed Apps with AKS HOL
    • Other Managed App Resources
    • SaaS Offer HOLs
    • SaaS Offer Video Series
      • Video 1 - SaaS Offer Overview
      • Video 2 - Purchasing a SaaS Offer
      • Video 3 - Purchasing a Private SaaS Plan
      • Video 4 - Publishing a SaaS Offer
      • Video 5 - Publishing a Private SaaS Plan
      • Video 6 - SaaS Offer Technical Overview
      • Video 7 - Azure AD Application Registrations
      • Video 8 - Using the SaaS Offer REST Fulfillment API
      • Video 9 - The SaaS Client Library for .NET
      • Video 10 - Building a Simple SaaS Landing Page in .NET
      • Video 11 - Building a Simple SaaS Publisher Portal in .NET
      • Video 12 - SaaS Webhook Overview
      • Video 13 - Implementing a Simple SaaS Webhook in .NET
      • Video 14 - Securing a Simple SaaS Webhook in .NET
      • Video 15 - SaaS Metered Billing Overview
      • Video 16 - The SaaS Metered Billing API with REST
  • Microsoft Fabric
    • Theory
    • Prereqs
    • Fabric Capacity
    • Set up a Remote State
    • Create a repo from a GitHub template
    • Configure an app reg for development
    • Initial Terraform workflow
    • Expanding your config
    • Configure a workload identity
    • GitHub Actions for Microsoft Fabric
    • GitLab pipeline for Microsoft Fabric
  • Packer & Ansible
    • Packer
    • Ansible
    • Dynamic Inventories
    • Playbooks & Roles
    • Custom Roles
    • Shared Image Gallery
  • Partner Admin Link
    • Understanding PAL
    • User and guest IDs
    • Service principals with credentials
    • CI/CD pipelines & OpenID Connect
    • Using AzAPI in Terraform
    • PAL tagging with a service principal
    • Azure Lighthouse & PAL
    • PAL FAQ
  • REST API
    • REST API theory
    • Using az rest
  • Setup
  • Sovereign landing zone
    • Overview
    • Run the ALZ Accelerator
      • Prereqs
      • Elevate
      • Bootstrap
      • Demote
      • Components
    • Deploy Sovereign landing zone
      • Create an initial SLZ config
      • Add a local override library
      • Test locally
      • Run through the CI/CD workflow
    • Understanding libraries
      • What is a library?
      • Policies, Assignments and Roles
      • Archetypes, Overrides and Architecture
      • Metadata and Policy Default Values
      • Custom libraries
    • Reference configs
      • Sovereign landing zone
      • Sovereign landing zone library with overrides
      • SLZ extended with a country pack
  • Terraform
    • Fundamentals
      • Initialise
      • Format
      • Validate
      • Plan
      • Apply
      • Adding resources
      • Locals and outputs
      • Managing state
      • Importing resources
      • Destroy
    • Get set up for Terraform
      • Cloud Shell
      • macOS
      • Windows with PowerShell
      • Windows with Ubuntu in WSL2
    • Using AzAPI
      • Using the REST API
      • azapi_resource
      • Removing azapi_resource
      • azapi_update_resource
      • Data sources and outputs
      • Removing azapi_update_resource
  • Virtual Machines
    • Azure Bastion with native tools & AAD
    • Managed Identities

  • About
  • Archive
  1. Home
  2. Blog
  3. Terraform MCP Server update

Table of Contents

  • What has changed?
    • HCP Terraform and Terraform Enterprise integration (v0.3.0)
    • Toolsets and tool filtering (v0.4.0)
    • Notable new tools
    • Additional IDE support
  • Is stdio still the right choice?
  • When does a shared hosted instance make sense?
  • Decision tree
  • Updating the Fabric Terraform series

Terraform MCP Server update

Richard Cheney • 02 Jun 2026

Table of Contents

  • What has changed?
    • HCP Terraform and Terraform Enterprise integration (v0.3.0)
    • Toolsets and tool filtering (v0.4.0)
    • Notable new tools
    • Additional IDE support
  • Is stdio still the right choice?
  • When does a shared hosted instance make sense?
  • Decision tree
  • Updating the Fabric Terraform series

The Terraform MCP Server has evolved significantly since I covered it in the Fabric Terraform series. It has moved well beyond a simple registry lookup tool and is now at v0.5.2. Here is a summary of what has changed and how to think about which configuration is right for you.

Note that this post was largely generated using GitHub Copilot CLI (Claude Opus 4.6) as I used it to compare my previous post with the new functionality rolled into the Terraform MCP server. I had a conversation to understand the changes, the most secure MCP server types, and the simplest route for most users given different scenarios. I figured the output was useful enough to warrant a quick blog post.

What has changed?

HCP Terraform and Terraform Enterprise integration (v0.3.0)

The biggest change. The server can now authenticate with HCP Terraform or Terraform Enterprise using TFE_TOKEN and TFE_ADDRESS environment variables, unlocking full workspace management via Copilot agent mode — creating and deleting workspaces, managing variables and tags, triggering runs, attaching policy sets, inspecting plan and apply logs, and more.

As a result the JSON configuration changed. For v0.3.0 and above you pass the credentials as environment variables into the Docker container:

{
  "servers": {
    "terraform": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e", "TFE_TOKEN=${input:tfe_token}",
        "-e", "TFE_ADDRESS=${input:tfe_address}",
        "hashicorp/terraform-mcp-server:0.5.2"
      ]
    }
  },
  "inputs": [
    {
      "type": "promptString",
      "id": "tfe_token",
      "description": "Terraform API Token",
      "password": true
    },
    {
      "type": "promptString",
      "id": "tfe_address",
      "description": "Terraform Address",
      "password": false
    }
  ]
}

The inputs block is a VS Code feature that prompts you securely for values at startup — a clean way to avoid hardcoding credentials.

If you are only using the public registry (no HCP Terraform or TFE), you do not need the credentials at all and the original simpler config still works fine — just pin a version tag:

{
  "servers": {
    "terraform": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "hashicorp/terraform-mcp-server:0.5.2"
      ]
    }
  }
}

Toolsets and tool filtering (v0.4.0)

With so many new tools the server now supports --toolsets and --tools flags to selectively enable groups or individual tools. The available toolsets are:

Toolset Description
registry Public Terraform Registry — providers, modules, policies
registry-private Private registry in HCP Terraform or TFE
terraform Workspace operations, runs, variables, policy sets, stacks
all Everything

The default is registry only, which keeps the tool count low and is appropriate for most developers. The 128-tool limit in GitHub Copilot agent mode is still worth keeping in mind.

Notable new tools

A flavour of what has been added across the versions:

  • v0.3.0: Workspaces, organisations, projects, workspace variables and tags, runs, variable sets, private registry
  • v0.3.2: get_provider_capabilities, create_no_code_workspace
  • v0.4.0: Policy sets, Stacks (list_stacks, get_stack_details), get_token_permissions
  • v0.5.0: get_plan_json_output, get_plan_details, get_plan_logs, get_apply_details, get_apply_logs
  • v0.5.3: get_sentinel_mock

Additional IDE support

The README now includes configuration examples for Cursor, Claude Desktop, Claude Code, Gemini, Amazon Q Developer, Kiro CLI, and Bob IDE — not just VS Code.

Is stdio still the right choice?

Yes, for individual developers. Stdio is actually the more secure transport — the MCP server runs as a child process communicating over stdin/stdout with no network port exposed. There is no remote attack surface.

The streamable HTTP transport opens a network port and requires additional hardening (CORS, TLS, rate limiting). HashiCorp’s own documentation recommends running locally at 127.0.0.1 and only exposing remotely with additional security controls in place. There is no public hosted HTTPS endpoint from HashiCorp for the registry.

When does a shared hosted instance make sense?

If your team has a private Terraform registry (HCP Terraform or Terraform Enterprise), hosting a single shared MCP server instance makes sense. Rather than every developer running Docker locally with their own token, you can centralise:

  • Credential management (TFE_TOKEN configured once)
  • Private registry and workspace tool access for the whole team
  • Credential rotation in one place

Azure Container Apps is the natural fit for this — it scales to zero when idle so costs nothing between uses, provides built-in HTTPS ingress, and supports managed identity for back-end authentication. Microsoft has official documentation for hosting MCP servers on ACA.

Decision tree

Scenario Recommended config
Solo dev, public registry only Local Docker, stdio, no credentials
Solo dev, HCP Terraform / TFE Local Docker, stdio, with TFE_TOKEN
Team, public registry only Local Docker per developer — no shared state needed
Team, private registry / HCP Terraform Shared Azure Container Apps instance

Updating the Fabric Terraform series

The Expanding your config page in the Fabric Terraform series uses the simple registry-only configuration, which still works. The only change worth making there is pinning the image version rather than using latest. If you are working with a team on a shared private registry, the ACA-hosted approach above is the upgrade path.

Source: https://www.azurecitadel.com/blog/2026-06-02-terraform-mcp-server-update/
Author: Richard Cheney
Published: 02 Jun 2026
Printed: