Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>InfraGraphNew to Visual Studio Code? Get it now.
InfraGraph

InfraGraph

Tunet

|
4 installs
| (0) | Free
VS Code extension for InfraGraph CLI with auto-setup, GitHub Copilot integration, and MCP support for seamless infrastructure management.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

InfraGraph VS Code Extension

This VS Code extension provides seamless integration with the InfraGraph CLI for infrastructure management. It includes the complete CLI bundled within the extension, eliminating the need for separate installation of Python or the CLI.

Key Features

  • Zero Configuration: The extension comes with everything needed - no additional setup required
  • Command Line Integration: Use the infragraph command from any terminal after installation
  • GitHub Copilot Integration: Use @infragraph commands directly in Copilot Chat
  • MCP Support: Full Model Context Protocol support for AI agents

Installation

  1. Install the extension from the VS Code Marketplace
  2. That's it! The extension automatically sets up the embedded Python environment and CLI

Setting up Terminal Integration

To make the infragraph command available in your terminal:

  1. Open VS Code Command Palette (Ctrl+Shift+P or Cmd+Shift+P)
  2. Run InfraGraph: Install Command-Line Integration
  3. Choose Copy to PATH in the prompt to make the command globally available

Using InfraGraph

After installation, you can use InfraGraph in several ways:

Within VS Code

  • Run InfraGraph commands directly from VS Code commands:
    • InfraGraph: Plan Scenario
    • InfraGraph: Apply Scenario
  • Use Copilot Chat integration with @infragraph commands:
    • @infragraph plan my-scenario
    • @infragraph apply --var region=us-east my-scenario

From Terminal

After setting up command-line integration, use the CLI directly:

# Basic commands
infragraph plan my-scenario
infragraph apply my-scenario

# With variables
infragraph plan --var region=us-east my-scenario

# Other CLI commands
infragraph validate
infragraph graph
infragraph operations list

Troubleshooting

If the infragraph command isn't available in your terminal after installation:

  1. Make sure you've run the InfraGraph: Install Command-Line Integration command
  2. Try restarting your terminal to refresh your PATH
  3. Check that the extension is properly installed in VS Code

For Developers

This extension bundles the InfraGraph CLI and a Python environment, making it self-contained. The following development information is for extension maintainers:

Building the Extension

  1. Install dependencies:

    npm install
    
  2. Bundle the CLI with the extension:

    npm run bundle-cli
    
  3. Build the extension:

    npm run compile
    
  4. Package the extension:

    npm run package
    

Development Notes

  • Edit src/embedded-extension.ts for embedded CLI integration
  • Edit src/extension.ts for chat and command logic
  • Edit package.json for commands and chat participant registration
  • Edit scripts/bundle-cli.js to modify CLI bundling behavior
  • Edit scripts/setup-python.ps1 to modify Python environment setup

For Copilot CLI integration, see .github/copilot-instructions.md in the main repo.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft