Skip to content

Latest commit

 

History

History
102 lines (74 loc) · 2.18 KB

File metadata and controls

102 lines (74 loc) · 2.18 KB

Connecting to Cursor IDE

Method 1: Cursor Settings UI

  1. Open Cursor
  2. Go to Settings: Ctrl+, (or Cmd+, on Mac)
  3. Search for "MCP" in the settings search bar
  4. Add MCP Server with these details:
    • Name: vps-initialize
    • Command: node
    • Arguments: ["/home/oxy/mcp-vps-initialize/dist/index.js"]
    • Environment: {"LOG_LEVEL": "info"}

Method 2: Configuration File

If Cursor supports MCP config files, place this in your Cursor config directory:

{
  "mcpServers": {
    "vps-initialize": {
      "command": "node",
      "args": ["/home/oxy/mcp-vps-initialize/dist/index.js"],
      "env": {
        "LOG_LEVEL": "info"
      }
    }
  }
}

Method 3: VS Code Compatible

If using VS Code with MCP extension:

  1. Install the MCP extension
  2. Add to your VS Code settings.json:
{
  "mcp.servers": {
    "vps-initialize": {
      "command": "node",
      "args": ["/home/oxy/mcp-vps-initialize/dist/index.js"],
      "env": {
        "LOG_LEVEL": "info"
      }
    }
  }
}

Testing the Connection

Once connected, try asking Cursor:

"Can you list the available VPS management tools?"

You should see tools like:

  • ssh_connect - Connect to VPS
  • vps_initialize - Setup services
  • nginx_setup - Configure domains
  • github_cicd_setup - Setup deployments
  • execute_command - Run commands

Example Usage

"Connect to my VPS at 192.168.1.100 with username 'root' and password 'mypassword', then install Node.js and Nginx"

The AI should be able to:

  1. Use the ssh_connect tool to establish connection
  2. Use the vps_initialize tool to install services
  3. Provide you with status updates and next steps

Troubleshooting

Server Not Found

  • Ensure the path /home/oxy/mcp-vps-initialize/dist/index.js exists
  • Run npm run build if the dist folder is missing

Permission Issues

  • Make sure the server file is executable
  • Check that Node.js is in your PATH

Connection Issues

  • Check the Cursor/VS Code console for error messages
  • Verify the MCP server starts correctly with npm start

Debug Mode

Set LOG_LEVEL to "debug" for more detailed logs:

"env": {
  "LOG_LEVEL": "debug"
}