Sign inSign up

mcprunner/mssqlmcp

By mcprunner

Updated 10 months ago

Image
0

2.3K

mcprunner/mssqlmcp repository overview

Docker Hub

This guide provides detailed instructions for deploying the SQL Server MCP (Model Context Protocol) Server using Docker.

Overview

This image is pushed to Docker Hub as mcprunner/mssqlmcp

Running Docker Image

Recommend using persistent storage for Data directory and secure method of replacing Variable values.


# MINGW64 Bash on Windows

MSYS_NO_PATHCONV=1  docker run -d \
  --name mssqlmcp \
  -p 3001:3001 \
  -e MSSQL_MCP_KEY="StrongEncryptionKeyForEncryptionOfYourConnectionStrings" \
  -e MSSQL_MCP_API_KEY="StrongApiKeyYourConnections" \
  -v "$(pwd)/data:/app/Data" \
  -v "$(pwd)/logs:/app/Logs" \
  mcprunner/mssqlmcp:latest;

Starting with standard bash is almost identical


# Standard Bash

docker run -d \
  --name mssqlmcp \
  -p 3001:3001 \
  -e MSSQL_MCP_KEY="StrongEncryptionKeyForEncryptionOfYourConnectionStrings" \
  -e MSSQL_MCP_API_KEY="StrongApiKeyYourConnections" \
  -v "$(pwd)/data:/app/Data" \
  -v "$(pwd)/logs:/app/Logs" \
  mcprunner/mssqlmcp:latest;

Visual Studio Code Setup

Update or create your .vscode/mcp.json file.

{
  "inputs": [
    {
      "id": "mssql-server-mcp-api-key",
      "type": "promptString",
      "description": "Enter your SQL Server MCP API Key",
      "password": true
    }
  ],
  "servers": {
    "sql-server-mcp": {
      "url": "http://localhost:3001",
      "headers": {
        "X-API-Key": "${input:mssql-server-mcp-api-key}",
        "Content-Type": "application/json"
      }
    }
  }
}

Starting in VSCode

Once added you should be able to hover over the "sql-server-mcp" and see "Start". Select Start and enter in the same API Key you started the docker image with.

Quick Examples of Usage and Architecture Overview

Source

https://github.com/MCPRUNNER/mssqlMCP

Troubleshooting

If you encounter issues:

  1. Check the container logs:

    docker logs mssqlmcp;
    
  2. Verify environment variables are set correctly:

    docker inspect mssqlmcp | grep -A 10 "Env";
    
  3. Ensure volume mounts have appropriate permissions:

    ls -la ./data ./logs;
    

Further Information

For more details on using the SQL Server MCP Server, refer to the main README.md and QUICK_INSTALL.md files in https://github.com/MCPRUNNER/mssqlMCP.

Tag summary

Content type

Image

Digest

sha256:18310ea10

Size

119.9 MB

Last updated

10 months ago

docker pull mcprunner/mssqlmcp