Skip to content

Instantly share code, notes, and snippets.

@ProxiBlue
Last active July 29, 2025 00:55
Show Gist options
  • Save ProxiBlue/456f1746bed04727ad8118873e19eaf2 to your computer and use it in GitHub Desktop.
Save ProxiBlue/456f1746bed04727ad8118873e19eaf2 to your computer and use it in GitHub Desktop.
MCP wrapper for junie and ddev projects
#!/bin/bash
source /home/lucas/.bash_profile
CONTAINER=$1
MCP=$2
cd $PROJECT_PATH
# If WORKING_DIR is set, change to that directory inside the container
if [ -n "$WORKING_DIR" ]; then
ddev exec -s $CONTAINER bash -c "cd $WORKING_DIR && npx -y $MCP"
else
ddev exec -s $CONTAINER npx -y $MCP
fi
@ProxiBlue
Copy link
Author

"project_mysql": {
      "command": "/home/lucas/ddev_mcp.sh",
      "args": [
        "mcp-container","@benborla29/mcp-server-mysql"
      ],
      "env": {
        "PROJECT_PATH": "/home/lucas/workspace/ittools/lcdscreen_mageos"
      }
    },
    "project_git": {
      "command": "/home/lucas/ddev_mcp.sh",
      "args": [
        "web","@cyanheads/git-mcp-server"
      ],
      "env": {
        "PROJECT_PATH": "/home/lucas/workspace/ittools/lcdscreen_mageos",
        "WORKING_DIR": "/var/www/html"
      }
    },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment