MCP server for Fly.io infrastructure management

MCP server for Fly.io infrastructure management

fly-mcp•bybrannn

An open-source Model Context Protocol server that exposes Fly.io management tools for AI-driven DevOps workflows.

License: MIT License•Runtime: Awaiting documentation review•Category: cloud devops

WHAT IT DOES

  • •Exposes Fly.io management tools over MCP, including listing apps with filtering, fetching app info, checking status, restarting with confirmation and scaling status.
  • •Implements the MCP protocol handler with full request/response handling over an HTTP server.
  • •Integrates with the Fly.io API through a hybrid approach using fly-go and the Machines API, with authentication and audit logging.

BEST FOR

  • •Managing Fly.io applications through natural-language AI DevOps interactions.
  • •Checking real-time application and machine status and restarting apps with explicit confirmation.

ABOUT FLY-MCP

MCP server for Fly.io infrastructure management is cataloged as an MCP server attributed to brannn. An open-source Model Context Protocol server that exposes Fly.io management tools for AI-driven DevOps workflows. It is categorized under cloud devops. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.

HOW TO INSTALL

Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.

LICENSE

Catalog license label: MIT License. Check the source repository's current license and terms before using, modifying or distributing this software.

能力检查器

能力定义尚未审核。未核验的采集内容不会作为可信接口展示。

Tools (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Resources (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

Prompts (0)

暂无可展示的已审核记录。这不表示上游不支持此能力。

NEWSLETTER - COMING LATER

Newsletter subscriptions are not open yet

Email delivery is not connected. This page does not collect email addresses or create subscriptions.

Browse the registry for current listings instead.

Community Reviews

Coming later

Reviews for MCP server for Fly.io infrastructure management are not available yet

Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.

FREQUENTLY ASKED QUESTIONS

Which Fly.io tools does this MCP server currently offer?

It offers ping, fly_list_apps, fly_app_info, fly_status, fly_restart and fly_scale.

Do destructive operations require confirmation?

Yes, destructive operations require explicit confirmation.

上游原版 README

在 GitHub 查看同一版本原文

README.md · de4b38a7a1f1 · 采集于 2026-11-13 11:06:29 UTC

保留上游原文,不做 AI 改写。为安全起见过滤脚本、表单和不安全链接。

当前显示最后一次成功采集的文档快照,请以来源页面为准。

fly-mcp

An open-source MCP (Model Context Protocol) server for Fly.io infrastructure management, enabling AI-driven DevOps workflows through natural language interactions.

🚀 Quick Start

Prerequisites

  • Go 1.21 or later
  • Fly.io account and API token
  • Git

Local Development Setup

  1. Clone the repository

    git clone https://github.com/brannn/fly-mcp.git
    cd fly-mcp
    
  2. Set up environment variables

    export FLY_MCP_FLY_API_TOKEN="your_fly_api_token_here"
    export FLY_MCP_FLY_ORGANIZATION="your_fly_org_here"
    
  3. Build and run

    make build
    make run
    

    Or for development with hot reload:

    make dev
    

Production Deployment on Fly.io

Deploy using Fly.io's MCP infrastructure:

fly mcp launch \
  "github.com/brannn/fly-mcp" \
  --claude --cursor --zed \
  --server fly-infrastructure \
  --secret FLY_API_TOKEN=fo1_your_token \
  --secret FLY_ORG=your-org-name

🏗️ Architecture

Project Structure

fly-mcp/
├── cmd/fly-mcp/              # Main application entry point
├── pkg/
│   ├── mcp/                  # MCP protocol implementation
│   ├── fly/                  # Fly.io API client (coming soon)
│   ├── auth/                 # Authentication (coming soon)
│   ├── tools/                # MCP tool implementations (coming soon)
│   └── config/               # Configuration management
├── internal/
│   ├── server/               # HTTP server implementation
│   ├── security/             # Security utilities (coming soon)
│   └── logger/               # Structured logging
├── config.local.yaml         # Local development configuration
├── config.production.yaml    # Production configuration
└── Makefile                  # Build automation

Configuration

The application supports flexible configuration through:

  • YAML files: config.local.yaml for development, config.production.yaml for production
  • Environment variables: All config values can be overridden with FLY_MCP_ prefixed env vars
  • Command line flags: --config and --log-level flags

Environment Variables

VariableDescriptionRequired
FLY_MCP_FLY_API_TOKENFly.io API tokenYes
FLY_MCP_FLY_ORGANIZATIONFly.io organization nameYes
FLY_MCP_ENVIRONMENTEnvironment (local/production)No
FLY_MCP_LOGGING_LEVELLog level (debug/info/warn/error)No

🛠️ Development

Available Make Targets

make build          # Build the binary
make build-all      # Build for all platforms
make test           # Run tests
make test-coverage  # Run tests with coverage
make lint           # Run linters
make fmt            # Format code
make clean          # Clean build artifacts
make dev            # Run in development mode
make validate-config # Validate configuration
make docker-build   # Build Docker image
make help           # Show all available targets

Running Tests

# Run all tests
make test

# Run tests with coverage
make test-coverage

# Run benchmarks
make benchmark

Code Quality

# Format code
make fmt

# Run linters
make lint

# Run all checks
make check

🔧 Configuration Examples

Local Development

Create a .env file or set environment variables:

export FLY_MCP_FLY_API_TOKEN="fo1_your_development_token"
export FLY_MCP_FLY_ORGANIZATION="your-dev-org"
export FLY_MCP_LOGGING_LEVEL="debug"

Production on Fly.io

Set secrets in your Fly.io app:

fly secrets set FLY_API_TOKEN=fo1_your_production_token
fly secrets set FLY_ORG=your-production-org

🛠️ Available MCP Tools

Core Tools

ToolDescriptionExample Usage
pingTest connectivity and server response{"name": "ping", "arguments": {"message": "Hello!"}}

Fly.io Management Tools

ToolDescriptionExample Usage
fly_list_appsList all applications with filtering{"name": "fly_list_apps", "arguments": {"status_filter": "running"}}
fly_app_infoGet detailed application information{"name": "fly_app_info", "arguments": {"app_name": "my-app"}}
fly_statusReal-time application and machine status{"name": "fly_status", "arguments": {"app_name": "my-app"}}
fly_restartRestart applications with confirmation{"name": "fly_restart", "arguments": {"app_name": "my-app", "confirm": true}}
fly_scaleScaling status and recommendations{"name": "fly_scale", "arguments": {"app_name": "my-app", "action": "status"}}

Tool Features

  • 🔒 Security: All tools require proper authentication and permissions
  • 📝 Audit Logging: All operations are logged for compliance and debugging
  • ⚡ Real-time: Status and machine information is fetched in real-time
  • 🛡️ Safety: Destructive operations require explicit confirmation
  • 📊 Rich Output: Human-readable responses with actionable recommendations

🧪 Testing the MCP Server

Automated Testing

Use the provided test script to verify all tools:

# Start the server first
make dev

# In another terminal, run tests
./scripts/test-mcp-tools.sh

Manual Testing

  1. Health Check

    curl http://localhost:8080/health
    
  2. MCP Initialize

    curl -X POST http://localhost:8080/mcp \
      -H "Content-Type: application/json" \
      -d '{
        "jsonrpc": "2.0",
        "id": 1,
        "method": "initialize",
        "params": {
          "protocolVersion": "2024-11-05",
          "capabilities": {},
          "clientInfo": {"name": "test-client", "version": "1.0.0"}
        }
      }'
    
  3. List Available Tools

    curl -X POST http://localhost:8080/mcp \
      -H "Content-Type: application/json" \
      -d '{
        "jsonrpc": "2.0",
        "id": 2,
        "method": "tools/list"
      }'
    
  4. Test Ping Tool

    curl -X POST http://localhost:8080/mcp \
      -H "Content-Type: application/json" \
      -d '{
        "jsonrpc": "2.0",
        "id": 3,
        "method": "tools/call",
        "params": {
          "name": "ping",
          "arguments": {"message": "Hello from fly-mcp!"}
        }
      }'
    
  5. Test Fly.io Tools (requires valid credentials)

    curl -X POST http://localhost:8080/mcp \
      -H "Content-Type: application/json" \
      -d '{
        "jsonrpc": "2.0",
        "id": 4,
        "method": "tools/call",
        "params": {
          "name": "fly_list_apps",
          "arguments": {}
        }
      }'
    

🎯 Current Status

Phase 2 Complete: Fly.io API Integration & Core Tools

✅ Implemented Features

  • ✅ Project structure and build system
  • ✅ Configuration management (local/production environments)
  • ✅ HTTP server with middleware (CORS, rate limiting, logging)
  • ✅ MCP protocol handler with full request/response handling
  • ✅ Structured logging with audit trails and security events
  • ✅ Fly.io API integration (hybrid approach: fly-go + Machines API)
  • ✅ Authentication & authorization with permissions and audit logging
  • ✅ Core MCP tools:
    • ping - Test tool for connectivity
    • fly_list_apps - List all applications with filtering
    • fly_app_info - Get detailed application information
    • fly_status - Real-time application and machine status
    • fly_restart - Restart applications with confirmation
    • fly_scale - Scaling status and recommendations
  • ✅ Health checks and metrics endpoints
  • ✅ Comprehensive error handling and validation
  • ✅ Security features (rate limiting, CORS, audit logging)

🔄 Coming Next (Phase 3)

  • 🔄 Additional tools: logs, secrets, volumes, certificates
  • 🔄 Deploy tool for application deployment
  • 🔄 Advanced scaling with auto-scaling recommendations
  • 🔄 Monitoring integration with alerts and dashboards
  • 🔄 CI/CD pipeline and automated testing
  • 🔄 Documentation and usage examples

📝 License

This project is licensed under the MIT License - see the LICENSE file for details.

🤝 Contributing

Contributions are welcome! Please see CONTRIBUTING.md for guidelines.

📞 Support

Install configuration

Are you the maintainer?

Claim this server with your GitHub account to request manual ownership verification.

README Embed Badge
Markdown

Link to the catalog listing for MCP server for Fly.io infrastructure management from your README. This badge does not certify ownership, compatibility or security.

[![MCP catalog listing](https://img.shields.io/badge/MCP-awesome--mcp-orange?style=flat-square)](https://awesome-mcp.com/servers/fly-mcp)

REPOSITORY STATS

GitHub StarsUnavailable
ForksUnavailable

Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.

下载与拉取统计

来源、范围和时段分别列出;不相加,不代表安装人数、活跃用户或安全审核。

尚无已审核的包 / 镜像标识,暂不展示下载统计。

Related cloud devops MCP Servers

Alternative and complementary servers in the same category

View all in cloud devops →
Huawei MCP Server
mcp-server-huaweiclouddeveloper•huaweiclouddeveloper

A Model Context Protocol server built on Huawei Cloud services that enables AI assistants to operate Huawei Cloud resources within conversational workflows, supporting ECS, OBS, GaussDB, and other cloud products.

Repository stats unavailable
Cloud & DevOps
Coolify MCP Server
coolify-mcp-server•wrediam

An MCP server that exposes the Coolify v4.3.1 REST API so AI clients can manage applications, databases, services, servers, deployments, and more.

Repository stats unavailable
Cloud & DevOps

A deprecated Model Context Protocol server for interacting with Kong Konnect APIs, enabling AI assistants to query and analyze Kong Gateway configurations, traffic, and analytics.

Repository stats unavailable
Cloud & DevOps